Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add 3 new syscalls: spawn, get_memory_limit and set_content #39

Merged
merged 7 commits into from
May 8, 2023
Merged

Add 3 new syscalls: spawn, get_memory_limit and set_content #39

merged 7 commits into from
May 8, 2023

Conversation

mohanson
Copy link
Collaborator

@mohanson mohanson commented Apr 26, 2023

Note:

  1. these syscalls only avaliable after ckb2023,
  2. and simulator is not currently implemented.

@XuJiandong XuJiandong self-requested a review April 27, 2023 05:31
src/syscalls/native.rs Show resolved Hide resolved
@jjyr
Copy link
Collaborator

jjyr commented May 8, 2023

Please use feature to control those syscalls.

#[cfg(features = "ckb2023")]
pub use ckb2023::*;

mod ckb2023 {
  pub fn spawn() { .. }
}

src/syscalls/native.rs Show resolved Hide resolved
@blckngm
Copy link
Collaborator

blckngm commented May 8, 2023

If we use (non-default) features, we should use

[package.metadata.docs.rs]
all-features = true

so that docs.rs will have docs for them.

Cargo.toml Outdated Show resolved Hide resolved
src/ckb_constants.rs Show resolved Hide resolved
@blckngm
Copy link
Collaborator

blckngm commented May 8, 2023

And there's the doc_auto_cfg feature for automatically generating only available on crate feature ... annotations. We should enable this on docs.rs.

@mohanson
Copy link
Collaborator Author

mohanson commented May 8, 2023

And there's the doc_auto_cfg feature for automatically generating only available on crate feature ... annotations. We should enable this on docs.rs.

doc_auto_cfg may not be used on the stable release channel

@jjyr jjyr merged commit e7d1004 into nervosnetwork:master May 8, 2023
@mohanson mohanson deleted the ckb2023 branch May 8, 2023 12:53
@blckngm
Copy link
Collaborator

blckngm commented May 8, 2023

doc_auto_cfg may not be used on the stable release channel

Docs.rs uses nightly. I'll submit a PR for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants