1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
// Copyright (c) 2025-2026 R3E Network
// Licensed under the MIT License
//! NEP standard-library macros (L5).
//!
//! These declarative macros were intended to emit the canonical NEP method
//! surface + Transfer event for a standard in one invocation.
//!
//! ## Status: unavailable on the current wasm32 export ABI
//!
//! A compliant NEP-17 / NEP-11 contract needs string method returns
//! (`symbol`, `name`) and Hash160 (`ByteString`) account/token-id
//! parameters. The `#[neo_method]` auto-export wrappers currently marshal
//! **scalar integer/boolean types only** across the wasm32 → NeoVM
//! boundary, so these macros cannot generate a working, standards-compliant
//! contract yet.
//!
//! Before v0.13.2 the macros emitted those signatures but the export
//! collector silently dropped every method (it matched the `#[neo_method]`
//! attribute by bare ident and missed the macro-emitted qualified
//! `#[$crate::neo_method]` form), so contracts built with them deployed
//! with **no callable methods**. As of v0.13.2 the attribute matching is
//! fixed and the macros fail to compile with actionable guidance instead of
//! producing a silently-broken contract.
//!
//! ## What to do instead
//!
//! Write the contract by hand with `#[neo_contract]` + `#[neo_method]`
//! using integer account ids — the same pattern every working example in
//! this repo uses. See `contracts/nep17-token` and `contracts/nep11-nft`
//! for complete, exported, callable token contracts.
/// NEP-17 (fungible token) standard macro.
///
/// **Currently unavailable on the wasm32 export ABI.** A compliant NEP-17
/// contract needs a `symbol()` method that returns a string and
/// `balanceOf`/`transfer` methods that take Hash160 (`ByteString`)
/// accounts. The `#[neo_method]` auto-export wrappers marshal scalar
/// integer/boolean types only, so this macro cannot emit a working,
/// standards-compliant contract yet. Any invocation therefore fails to
/// compile with guidance rather than silently exporting no methods (the
/// behaviour before v0.13.2).
///
/// Until the typed-parameter export ABI lands, write the contract by hand
/// with `#[neo_contract]` + `#[neo_method]` using integer account ids —
/// see `contracts/nep17-token` for a complete working example.
/// NEP-11 (non-fungible token) standard macro.
///
/// **Currently unavailable on the wasm32 export ABI**, for the same reason
/// as [`nep17!`]: the NEP-11 surface (`symbol`/`name` string returns,
/// Hash160/ByteString accounts and token ids) cannot be marshalled through
/// the scalar-only `#[neo_method]` export wrappers. Any invocation fails to
/// compile with guidance rather than silently exporting no methods.
///
/// Write the contract by hand with `#[neo_contract]` + `#[neo_method]`
/// until the typed-parameter export ABI lands — see `contracts/nep11-nft`.