diff --git a/noir-projects/aztec-nr/aztec/src/note/note_metadata.nr b/noir-projects/aztec-nr/aztec/src/note/note_metadata.nr index e006b361f654..8bd6c2bc36a7 100644 --- a/noir-projects/aztec-nr/aztec/src/note/note_metadata.nr +++ b/noir-projects/aztec-nr/aztec/src/note/note_metadata.nr @@ -68,13 +68,13 @@ impl NoteMetadata { } } - /// Returns true if the note is pending **and** from the same phase, i.e. if it's been created in the current + /// Returns `true` if the note is pending **and** from the same phase, i.e. if it's been created in the current /// transaction during the current execution phase (either non-revertible or revertible). pub fn is_pending_same_phase(self) -> bool { self.stage == NoteStage.PENDING_SAME_PHASE } - /// Returns true if the note is pending **and** from the previous phase, i.e. if it's been created in the current + /// Returns `true` if the note is pending **and** from the previous phase, i.e. if it's been created in the current /// transaction during an execution phase prior to the current one. Because private execution only has two phases /// with strict ordering, this implies that the note was created in the non-revertible phase, and that the current /// phase is the revertible phase. @@ -82,7 +82,7 @@ impl NoteMetadata { self.stage == NoteStage.PENDING_PREVIOUS_PHASE } - /// Returns true if the note is settled, i.e. if it's been created in a prior transaction and is therefore already + /// Returns `true` if the note is settled, i.e. if it's been created in a prior transaction and is therefore already /// in the note hash tree. pub fn is_settled(self) -> bool { self.stage == NoteStage.SETTLED diff --git a/noir-projects/aztec-nr/aztec/src/oracle/nullifiers.nr b/noir-projects/aztec-nr/aztec/src/oracle/nullifiers.nr index 323028dac4db..7c8e64a85574 100644 --- a/noir-projects/aztec-nr/aztec/src/oracle/nullifiers.nr +++ b/noir-projects/aztec-nr/aztec/src/oracle/nullifiers.nr @@ -14,7 +14,7 @@ pub fn notify_created_nullifier(inner_nullifier: Field) { #[oracle(aztec_prv_notifyCreatedNullifier)] unconstrained fn notify_created_nullifier_oracle(_inner_nullifier: Field) {} -/// Returns true if the nullifier has been emitted in the same transaction, i.e. if [`notify_created_nullifier`] has +/// Returns `true` if the nullifier has been emitted in the same transaction, i.e. if [`notify_created_nullifier`] has /// been /// called for this inner nullifier from the contract with the specified address. /// @@ -29,7 +29,7 @@ pub unconstrained fn is_nullifier_pending(inner_nullifier: Field, contract_addre #[oracle(aztec_prv_isNullifierPending)] unconstrained fn is_nullifier_pending_oracle(_inner_nullifier: Field, _contract_address: AztecAddress) -> bool {} -/// Returns true if the nullifier exists. Note that a `true` value can be constrained by proving existence of the +/// Returns `true` if the nullifier exists. Note that a `true` value can be constrained by proving existence of the /// nullifier, but a `false` value should not be relied upon since other transactions may emit this nullifier before /// the current transaction is included in a block. While this might seem of little use at first, certain design /// patterns benefit from this abstraction (see e.g. `PrivateMutable`). diff --git a/noir-projects/aztec-nr/aztec/src/state_vars/private_immutable.nr b/noir-projects/aztec-nr/aztec/src/state_vars/private_immutable.nr index 8e3acdf200ba..ef84849f3ebb 100644 --- a/noir-projects/aztec-nr/aztec/src/state_vars/private_immutable.nr +++ b/noir-projects/aztec-nr/aztec/src/state_vars/private_immutable.nr @@ -143,7 +143,7 @@ where self.compute_initialization_nullifier(secret) } - /// Returns whether this PrivateImmutable has been initialized. + /// Returns `true` if this PrivateImmutable has been initialized. pub unconstrained fn is_initialized(self) -> bool { let nullifier = self.get_initialization_nullifier(); check_nullifier_exists(nullifier) diff --git a/noir-projects/aztec-nr/aztec/src/state_vars/public_immutable.nr b/noir-projects/aztec-nr/aztec/src/state_vars/public_immutable.nr index b001b4161c6e..da21ab7d3a1c 100644 --- a/noir-projects/aztec-nr/aztec/src/state_vars/public_immutable.nr +++ b/noir-projects/aztec-nr/aztec/src/state_vars/public_immutable.nr @@ -214,7 +214,7 @@ impl PublicImmutable { WithHash::public_storage_read(self.context, self.storage_slot) } - /// Returns true if the `PublicImmutable` has been initialized. + /// Returns `true` if the `PublicImmutable` has been initialized. /// /// ## Examples: /// @@ -263,7 +263,7 @@ impl PublicImmutable { WithHash::utility_public_storage_read(self.context, self.storage_slot) } - /// Returns true if the `PublicImmutable` has been initialized. + /// Returns `true` if the `PublicImmutable` has been initialized. pub unconstrained fn is_initialized(self) -> bool { let nullifier = self.compute_initialization_inner_nullifier(); check_nullifier_exists(nullifier) diff --git a/noir-projects/aztec-nr/aztec/src/state_vars/single_private_immutable.nr b/noir-projects/aztec-nr/aztec/src/state_vars/single_private_immutable.nr index 8a83efad2e79..326a4843110d 100644 --- a/noir-projects/aztec-nr/aztec/src/state_vars/single_private_immutable.nr +++ b/noir-projects/aztec-nr/aztec/src/state_vars/single_private_immutable.nr @@ -158,7 +158,7 @@ where self.compute_initialization_nullifier(secret) } - /// Returns whether this SinglePrivateImmutable has been initialized. + /// Returns `true` if this SinglePrivateImmutable has been initialized. pub unconstrained fn is_initialized(self) -> bool { let nullifier = self.get_initialization_nullifier(); check_nullifier_exists(nullifier) diff --git a/noir-projects/aztec-nr/aztec/src/state_vars/single_private_mutable.nr b/noir-projects/aztec-nr/aztec/src/state_vars/single_private_mutable.nr index e2c0e05d7625..d286aa346b78 100644 --- a/noir-projects/aztec-nr/aztec/src/state_vars/single_private_mutable.nr +++ b/noir-projects/aztec-nr/aztec/src/state_vars/single_private_mutable.nr @@ -249,7 +249,7 @@ where self.compute_initialization_nullifier(secret) } - /// Returns whether this SinglePrivateImmutable has been initialized. + /// Returns `true` if this SinglePrivateMutable has been initialized. pub unconstrained fn is_initialized(self) -> bool { let nullifier = self.get_initialization_nullifier(); check_nullifier_exists(nullifier) diff --git a/noir-projects/aztec-nr/aztec/src/state_vars/single_use_claim.nr b/noir-projects/aztec-nr/aztec/src/state_vars/single_use_claim.nr index 2edf233a6f9c..4945119afbc7 100644 --- a/noir-projects/aztec-nr/aztec/src/state_vars/single_use_claim.nr +++ b/noir-projects/aztec-nr/aztec/src/state_vars/single_use_claim.nr @@ -132,7 +132,7 @@ impl SingleUseClaim<&mut PrivateContext> { } impl SingleUseClaim { - /// Returns whether an owner has claimed this single use claim. + /// Returns `true` if an owner has claimed this single use claim. pub unconstrained fn has_claimed(self) -> bool { let owner_nhk_app = get_nhk_app(get_public_keys(self.owner).npk_m.hash()); check_nullifier_exists(self.compute_nullifier(owner_nhk_app))