【发布时间】:2021-01-11 04:33:03
【问题描述】:
我正在为 NEAR 区块链编写智能合约承诺接口。
我有如下界面:
#[ext_contract(token_receiver)]
pub trait ExtTokenReceiver {
fn process_token_received(&self, sender_id: AccountId, amount: Balance, message: [u8]) -> Option<String>;
}
但是这会失败并出现以下错误:
error: Unsupported argument type.
--> src/token.rs:32:1
|
32 | #[ext_contract(token_receiver)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: this error originates in an attribute macro (in Nightly builds, run with -Z macro-backtrace for more info)
- 如何调试 Near-bindgen 宏
- 在这种情况下
Unsupported argument type是什么 - 如何修复我的界面
【问题讨论】:
标签: rust nearprotocol