We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Macro that adds an external method that returns the commit hash of the build.
This should be possible because macros run at compile time.
Existing similar NEP: https://github.com/near/NEPs/blob/master/neps/nep-0330.md
trait BuildId { fn build_id(&self) -> String; } #[derive(BuildId)] #[derive(BorshSerialize, BorshDeserialize, PanicOnDefault)] #[near_bindgen] pub struct MyContract { // ... } let contract = MyContract::new(); println!("{}", contract.build_id()); // 6a5992033dc4a092a5d45d64b4f205ce9aeb2939
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Macro that adds an external method that returns the commit hash of the build.
This should be possible because macros run at compile time.
Existing similar NEP: https://github.com/near/NEPs/blob/master/neps/nep-0330.md
Possible Example Usage
The text was updated successfully, but these errors were encountered: