From da0acc99fa9f55ab5cba39030d59f7ce7d52028e Mon Sep 17 00:00:00 2001 From: EthanYuan Date: Tue, 15 Aug 2023 15:34:38 +0800 Subject: [PATCH] fixing typos in comments --- util/jsonrpc-types/src/blockchain.rs | 8 ++++---- util/types/src/core/blockchain.rs | 2 +- util/types/src/core/tx_pool.rs | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/util/jsonrpc-types/src/blockchain.rs b/util/jsonrpc-types/src/blockchain.rs index 2df38a7959..bf40d24f8e 100644 --- a/util/jsonrpc-types/src/blockchain.rs +++ b/util/jsonrpc-types/src/blockchain.rs @@ -13,7 +13,7 @@ use std::fmt; /// Specifies how the script `code_hash` is used to match the script code and how to run the code. /// -/// Allowed kinds: "data", "type", "data1" and “data2” +/// Allowed kinds: "data", "type", "data1" and "data2" /// /// Refer to the section [Code Locating](https://github.com/nervosnetwork/rfcs/blob/master/rfcs/0022-transaction-structure/0022-transaction-structure.md#code-locating) /// and [Upgradable Script](https://github.com/nervosnetwork/rfcs/blob/master/rfcs/0022-transaction-structure/0022-transaction-structure.md#upgradable-script) @@ -384,7 +384,7 @@ pub struct Transaction { pub version: Version, /// An array of cell deps. /// - /// CKB locates lock script and type script code via cell deps. The script also can uses syscalls + /// CKB locates lock script and type script code via cell deps. The script also can use syscalls /// to read the cells here. /// /// Unlike inputs, the live cells can be used as cell deps in multiple transactions. @@ -536,7 +536,7 @@ pub struct TransactionWithStatusResponse { pub transaction: Option>, /// The transaction consumed cycles. pub cycles: Option, - /// If the transaction is in tx-pool, `time_added_to_pool` represent when it enter the tx-pool. unit: Millisecond + /// If the transaction is in tx-pool, `time_added_to_pool` represent when it enters the tx-pool. unit: Millisecond pub time_added_to_pool: Option, /// The Transaction status. pub tx_status: TxStatus, @@ -1461,7 +1461,7 @@ pub struct Buried { pub status: SoftForkStatus, /// Whether the rules are active pub active: bool, - /// The first epoch which the rules will be enforced + /// The first epoch which the rules will be enforced pub epoch: EpochNumber, } diff --git a/util/types/src/core/blockchain.rs b/util/types/src/core/blockchain.rs index 7121bf09de..9dc2e7cb73 100644 --- a/util/types/src/core/blockchain.rs +++ b/util/types/src/core/blockchain.rs @@ -6,7 +6,7 @@ use crate::packed; /// The hash type is split into the high 7 bits and the low 1 bit, /// when the low 1 bit is 1, it indicates the type, /// when the low 1 bit is 0, it indicates the data, -/// and then it relies on the high 7 bits to indicate +/// and then it relies on the high 7 bits to indicate /// that the data actually corresponds to the version. #[derive(Clone, Copy, PartialEq, Eq, Hash, Debug)] pub enum ScriptHashType { diff --git a/util/types/src/core/tx_pool.rs b/util/types/src/core/tx_pool.rs index d5b41e1d4d..a1f182905d 100644 --- a/util/types/src/core/tx_pool.rs +++ b/util/types/src/core/tx_pool.rs @@ -161,7 +161,7 @@ pub struct TransactionWithStatus { pub tx_status: TxStatus, /// The transaction verification consumed cycles pub cycles: Option, - /// If the transaction is in tx-pool, `time_added_to_pool` represent when it enter the tx-pool. unit: Millisecond + /// If the transaction is in tx-pool, `time_added_to_pool` represent when it enters the tx-pool. unit: Millisecond pub time_added_to_pool: Option, }