找到约 12 条结果

文章 区块链中的数学-secp256k1公钥恢复实现

...f (recId == -1) { throw new RuntimeException( "Could not construct a recoverable key. This should never happen."); } ** sig.v = (byte) (recId + ECDSASignature.vBase);** return sig; } ``` 恢复过程根据[公钥恢复原理](https://learnblockchain.cn/arti...

文章 Substrate代码导读:node-template

...类型; * 为runtime的实现各个功能模块的接口,runtime由`construct_runtime`宏生成, ``` impl template::Trait for Runtime { type Event = Event; } ``` * `construct_runtime`宏根据名称(如`TemplateModule`)和所用的模块内的组件(如`templa...

文章 Ordinal NFT实现原理及Bitcoin Regtest测试网Mint教程

...//docs.lightning.engineering/the-lightning-network/taro/taro-protocol) - [constructing-and-spending-taproot-outputs](https://github.com/bitcoin/bips/blob/master/bip-0341.mediawiki#constructing-and-spending-taproot-outputs) - [tapscript-example-with-tap](https://github.com/bitcoin-core/btcdeb/blob/...

文章 入门 Sui Move 开发:8. PTB 以及 Sui TS SDK 的使用

...l. --make-move-vec Given n-values of the same type, it constructs a vector. For non objects or an empty vector, the type tag must be specified. --merge-coins Merge N coins into the provided coin. --move-call Make a move call to a function....

文章 Go 语言之在 Gin 框架中使用 Zap 实现高效日志管理

...re := zapcore.NewCore(encoder, writeSyncer, zapcore.DebugLevel) // New constructs a new Logger from the provided zapcore.Core and Options. If // the passed zapcore.Core is nil, it falls back to using a no-op // implementation. // AddCaller configures the Logger to annotate each message w...

文章 BOLT 3:比特币交易和脚本格式

...nsactions) * [Dust Limits](#dust-limits) * [Commitment Transaction Construction](#commitment-transaction-construction) * [密钥](#keys) * [密钥推导](#key-derivation) * [`localpubkey`, `remotepubkey`, `local_htlcpubkey`, `remote_htlcpubkey`, `local_delayedpubkey` 和 `remot...

问题 solidity的struct中包含了mapping,在使用中报内存初始化错误

...: ``` 错误提示:struct contraining a (nested) mapping cannot be constructed ``` 请教该怎么处理? 找了一下文档:https://docs.soliditylang.org/en/v0.7.1/070-breaking-changes.html#mappings-outside-storage 文档的意思是0.7版本后优化了这些不安全的写法...

文章 Web3 极客日报 #1559

...l-framework/ **Harry**: 可以用它来实现一个叫做 Strobe Duplex Construction 的 primitive。实现的 Strobe 对象应能响应十几种调用,将这些调用组合在一起,就能生成随机数、派生密钥、散列、加密、验证,甚至构建复杂的对称协议。

文章 用Substrate框架实现一个简单的游戏应用

... 最后,我们需要在运行时构造函数中包含demo模块: ``` construct_runtime!( pub enum Runtime with Log(InternalLog: DigestItem) where Block = Block, NodeBlock = opaque::Block, UncheckedExtrinsic = UncheckedExtrinsic { System: system::{default, Log(ChangesT...

文章 sui-move基础(三):letsmove-task2

...mation about the transaction currently being executed. /// This cannot be constructed by a transaction--it is a privileged object created by /// the VM and passed in to the entrypoint of the transaction as `&mut TxContext`. public struct TxContext has drop { /// The address of the user that ...

文章 Libra 白皮书中英文对照版

...lability of the protocol and implementation. * The Libra Association will construct well-documented APIs and libraries to enable users to interact with the Libra Blockchain. * The Libra Association will create a framework for the collaborative development of the technology behind the Libra Blockcha...

文章 Sui Move 学习:Object & 四种能力

...ate an instance of the `IgnoreMe` struct and ignore it. // Even though we constructed the instance, we don't need to unpack it. fun test_ignore() { let no_drop = NoDrop {}; let _ = IgnoreMe { a: 1, b: 2 }; // no need to unpack // The value must be unpacked for the code to compile....