Skip to content

Commit f29575c

Browse files
docs test fix
1 parent 49bc57b commit f29575c

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ jobs:
123123
env:
124124
RUSTDOCFLAGS: -D warnings
125125
run: |
126-
cargo doc -p near-sdk --features unstable,legacy,unit-testing,__macro-docs
126+
cargo doc -p near-sdk --features unstable,legacy,unit-testing,__macro-docs,near-primitives,near-vm-runner
127127
cargo doc -p near-sdk-macros
128128
cargo doc -p near-contract-standards --no-deps
129129
cargo doc -p near-sys

near-sdk-macros/src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ struct NearMacroArgs {
6868
/// impl Adder {
6969
/// #[result_serializer(borsh)]
7070
/// pub fn borsh_parameters(&self, #[serializer(borsh)] a: Pair, #[serializer(borsh)] b: Pair) -> Pair {
71-
/// ...
71+
/// /// ...
7272
// }
7373
/// ```
7474
///
@@ -81,7 +81,7 @@ struct NearMacroArgs {
8181
/// impl Adder {
8282
/// #[result_serializer(borsh)]
8383
/// pub fn borsh_parameters(&self) -> Pair {
84-
/// ...
84+
/// /// ...
8585
// }
8686
/// ```
8787
///
@@ -316,8 +316,8 @@ pub fn near(attr: TokenStream, item: TokenStream) -> TokenStream {
316316
TokenStream::from(expanded)
317317
}
318318

319-
/// This macro is deprecated. Use [#[near]](./attr.near.html) instead. The difference between #[near] and #[near_bindgen] is that
320-
/// with #[near_bindgen] you have to manually add boilerplate code for structs and enums so that they become Json- and Borsh-serializable:
319+
/// This macro is deprecated. Use [#[macro@near]](./attr.near.html) instead. The difference between #[macro@near] and #[macro@near_bindgen] is that
320+
/// with #[macro@near_bindgen] you have to manually add boilerplate code for structs and enums so that they become Json- and Borsh-serializable:
321321
/// ```ignore
322322
/// #[near_bindgen]
323323
/// #[derive(BorshSerialize, BorshDeserialize, NearSchema)]

near-sdk/src/environment/env.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1390,6 +1390,7 @@ pub fn promise_batch_action_delete_account(
13901390
/// assert_eq!(promise_results_count(), 0);
13911391
/// ```
13921392
/// More low-level info here: [`near_vm_runner::logic::VMLogic::promise_results_count`]
1393+
/// See example of usage [here](https://github.com/near/near-sdk-rs/blob/master/examples/cross-contract-calls/low-level/src/lib.rs)
13931394
pub fn promise_results_count() -> u64 {
13941395
unsafe { sys::promise_results_count() }
13951396
}
@@ -1419,6 +1420,7 @@ pub fn promise_results_count() -> u64 {
14191420
/// };
14201421
/// ```
14211422
/// More low-level info here: [`near_vm_runner::logic::VMLogic::promise_result`]
1423+
/// Example usages: [one](https://github.com/near/near-sdk-rs/blob/189897180649bce47aefa4e5af03664ee525508d/near-contract-standards/src/fungible_token/core_impl.rs#L178), [two](https://github.com/near/near-sdk-rs/blob/189897180649bce47aefa4e5af03664ee525508d/near-contract-standards/src/non_fungible_token/core/core_impl.rs#L433), [three](https://github.com/near/near-sdk-rs/blob/189897180649bce47aefa4e5af03664ee525508d/examples/factory-contract/low-level/src/lib.rs#L61), [four](https://github.com/near/near-sdk-rs/blob/189897180649bce47aefa4e5af03664ee525508d/examples/cross-contract-calls/low-level/src/lib.rs#L46)
14221424
pub fn promise_result(result_idx: u64) -> PromiseResult {
14231425
match promise_result_internal(result_idx) {
14241426
Ok(()) => {

0 commit comments

Comments
 (0)