diff --git a/src/lib_context/sigs/context.ml b/src/lib_context/sigs/context.ml index bda59c4292d6e22f03412d0f64df4b4f9f8e45b4..5f52f172ecc7395e93b316c9ac4ae1693f3d487b 100644 --- a/src/lib_context/sigs/context.ml +++ b/src/lib_context/sigs/context.ml @@ -382,7 +382,7 @@ module Proof_types = struct [Blinded_inode h] proves that an inode with hash [h] exists in the store. - [Inode_values ls] is simliar to trees' [Node]. + [Inode_values ls] is similar to trees' [Node]. [Inode_tree i] is similar to tree's [Inode]. @@ -437,7 +437,7 @@ module Proof_types = struct (** The type for stream proofs. - The sequance [e_1 ... e_n] proves that the [e_1], ..., [e_n] are + The sequence [e_1 ... e_n] proves that the [e_1], ..., [e_n] are read in the store in sequence. *) type t = unit -> elt Seq.node end diff --git a/src/lib_lwt_result_stdlib/bare/sigs/list.ml b/src/lib_lwt_result_stdlib/bare/sigs/list.ml index 9c01603c8c93c6db4db857d5b68c18f9f23fa242..f09205f0325e575299266145ce6796cd4a61ee3a 100644 --- a/src/lib_lwt_result_stdlib/bare/sigs/list.ml +++ b/src/lib_lwt_result_stdlib/bare/sigs/list.ml @@ -383,7 +383,7 @@ module type S = sig The function stops early if it encounters elements [xn], [yn] such that [f xn yn] is [false]. (This is consistent with the short-circuit, lazy - evaluation strategy of [&&] in the descritpion above.) + evaluation strategy of [&&] in the description above.) Also note that, if such an element is found in the common prefix of [xs] and [ys], then the function returns [Ok false] even if [xs] and [ys] are @@ -421,7 +421,7 @@ module type S = sig The function stops early if it encounters elements [xn], [yn] such that [f xn yn] is [true]. (This is consistent with the short-circuit, lazy - evaluation strategy of [||] in the descritpion above.) + evaluation strategy of [||] in the description above.) Also note that, if such an element is found in the common prefix of [xs] and [ys], then the function returns [Ok true] even if [xs] and [ys] are of diff --git a/src/lib_protocol_environment/environment_cache.mli b/src/lib_protocol_environment/environment_cache.mli index 01383974f11d3c99add969df87559a26cfd24c37..bee3fab4855464f0851a3cc3a416e52cbdbbf95c 100644 --- a/src/lib_protocol_environment/environment_cache.mli +++ b/src/lib_protocol_environment/environment_cache.mli @@ -288,7 +288,7 @@ val list_keys : 'value t -> cache_index:index -> (key * size) list option cache. *) val key_rank : 'value t -> key -> int option -(** [pp fmt cache] is a pretty printter for a [cache]. *) +(** [pp fmt cache] is a pretty printer for a [cache]. *) val pp : Format.formatter -> 'value t -> unit (**/**) diff --git a/src/lib_protocol_environment/sigs/v7.ml b/src/lib_protocol_environment/sigs/v7.ml index 624f75b9a48c4c0423f95b16f080437d956baca7..2204b3e433aca770c200de47a5926a95d63f6165 100644 --- a/src/lib_protocol_environment/sigs/v7.ml +++ b/src/lib_protocol_environment/sigs/v7.ml @@ -3007,10 +3007,11 @@ let () = -(** We omit [dont_wait] and other such functions because we it is only useful in - mutation-heavy loosely-synchronised code which the protocol shouldn't be. *) +(** We omit [dont_wait] and other such functions because they are only useful + in mutation-heavy loosely-synchronised code which the protocol shouldn't be. + *) -(** We omit many synchronisation primitives such as [choose] because it +(** We omit many synchronisation primitives such as [choose] because they introduce non-determinism. *) (** We omit cancelation-related primitives because we discourage Cancelation in @@ -3884,7 +3885,7 @@ val splitted : json:'a encoding -> binary:'a encoding -> 'a encoding A stateful recursive encoding can still be put under a [delayed] combinator to make sure that a new encoding is generated each time it is used. Caching the encoding generation when the state - has not changed is then the responsability of the client. + has not changed is then the responsibility of the client. *) val mu : @@ -4829,7 +4830,7 @@ module Result (Ok : COMPARABLE) (Error : COMPARABLE) : {[ if Compare.List_length_with.(chunks > max_number_of_chunks) then - raise Maximum_size_exceeeded + raise Maximum_size_exceeded else .. ]} @@ -6243,7 +6244,7 @@ val fold_right2 : The function stops early if it encounters elements [xn], [yn] such that [f xn yn] is [false]. (This is consistent with the short-circuit, lazy - evaluation strategy of [&&] in the descritpion above.) + evaluation strategy of [&&] in the description above.) Also note that, if such an element is found in the common prefix of [xs] and [ys], then the function returns [Ok false] even if [xs] and [ys] are @@ -6281,7 +6282,7 @@ val for_all2 : The function stops early if it encounters elements [xn], [yn] such that [f xn yn] is [true]. (This is consistent with the short-circuit, lazy - evaluation strategy of [||] in the descritpion above.) + evaluation strategy of [||] in the description above.) Also note that, if such an element is found in the common prefix of [xs] and [ys], then the function returns [Ok true] even if [xs] and [ys] are of @@ -7245,7 +7246,7 @@ val to_list : 'a t -> 'a list (**/**) -(* This Array module is the thinest shim we can get away with for use with Plonk. +(* This Array module is the thinnest shim we can get away with for use with Plonk. To avoid any issues with arrays — notably to avoid exceptions when getting out of bounds and to avoid any issues with mutability — we shadow [get] and [set] as well as a few other functions. @@ -10605,7 +10606,7 @@ module Proof : sig [Blinded_inode h] proves that an inode with hash [h] exists in the store. - [Inode_values ls] is simliar to trees' [Node]. + [Inode_values ls] is similar to trees' [Node]. [Inode_tree i] is similar to tree's [Inode]. @@ -10660,7 +10661,7 @@ module Proof : sig (** The type for stream proofs. - The sequance [e_1 ... e_n] proves that the [e_1], ..., [e_n] are + The sequence [e_1 ... e_n] proves that the [e_1], ..., [e_n] are read in the store in sequence. *) type t = elt Seq.t end @@ -10845,7 +10846,7 @@ module type CACHE = sig [key]. *) val identifier_of_key : key -> identifier - (** [pp fmt cache] is a pretty printter for a [cache]. *) + (** [pp fmt cache] is a pretty printer for a [cache]. *) val pp : Format.formatter -> t -> unit (** [find ctxt k = Some v] if [v] is the value associated to [k] in @@ -10910,7 +10911,7 @@ module type CACHE = sig This function is based on a heuristic. The context maintains the median of the number of removed entries: this number is - multipled by `n_blocks` to determine the entries that are + multiplied by `n_blocks` to determine the entries that are likely to be removed in `n_blocks`. *) val future_cache_expectation : t -> time_in_blocks:int -> t @@ -11606,7 +11607,7 @@ val segment_proof_encoding : segment_proof Data_encoding.t (** [verify_segment t commitment segment segment_proof] returns [Ok true] if the [proof] certifies that the [slot_segment] is indeed included in the slot committed with commitment - [comitment]. Returns [Ok false] otherwise. + [commitment]. Returns [Ok false] otherwise. Fails if the index of the segment is out of range. *) val verify_segment : diff --git a/src/lib_protocol_environment/sigs/v7/array.mli b/src/lib_protocol_environment/sigs/v7/array.mli index 89ee526682717ecc1172e16f7bbb31acfc6ab087..d990f7c9069baabe35fa3f685f0c0b656ca8cf0e 100644 --- a/src/lib_protocol_environment/sigs/v7/array.mli +++ b/src/lib_protocol_environment/sigs/v7/array.mli @@ -43,7 +43,7 @@ val to_list : 'a t -> 'a list (**/**) -(* This Array module is the thinest shim we can get away with for use with Plonk. +(* This Array module is the thinnest shim we can get away with for use with Plonk. To avoid any issues with arrays — notably to avoid exceptions when getting out of bounds and to avoid any issues with mutability — we shadow [get] and [set] as well as a few other functions. diff --git a/src/lib_protocol_environment/sigs/v7/compare.mli b/src/lib_protocol_environment/sigs/v7/compare.mli index 0437dd1e23de5ed838b312bd66370f404b6a750c..61d756f56afc7f080e7565535bf4aad42475e4ed 100644 --- a/src/lib_protocol_environment/sigs/v7/compare.mli +++ b/src/lib_protocol_environment/sigs/v7/compare.mli @@ -161,7 +161,7 @@ module Result (Ok : COMPARABLE) (Error : COMPARABLE) : {[ if Compare.List_length_with.(chunks > max_number_of_chunks) then - raise Maximum_size_exceeeded + raise Maximum_size_exceeded else .. ]} diff --git a/src/lib_protocol_environment/sigs/v7/context.mli b/src/lib_protocol_environment/sigs/v7/context.mli index 4d7ccd466b7314dcac0880d9feef30113e92ca52..2e0ce50f937e0e908f07fca64147e7a6b593a73d 100644 --- a/src/lib_protocol_environment/sigs/v7/context.mli +++ b/src/lib_protocol_environment/sigs/v7/context.mli @@ -301,7 +301,7 @@ module Proof : sig [Blinded_inode h] proves that an inode with hash [h] exists in the store. - [Inode_values ls] is simliar to trees' [Node]. + [Inode_values ls] is similar to trees' [Node]. [Inode_tree i] is similar to tree's [Inode]. @@ -356,7 +356,7 @@ module Proof : sig (** The type for stream proofs. - The sequance [e_1 ... e_n] proves that the [e_1], ..., [e_n] are + The sequence [e_1 ... e_n] proves that the [e_1], ..., [e_n] are read in the store in sequence. *) type t = elt Seq.t end @@ -541,7 +541,7 @@ module type CACHE = sig [key]. *) val identifier_of_key : key -> identifier - (** [pp fmt cache] is a pretty printter for a [cache]. *) + (** [pp fmt cache] is a pretty printer for a [cache]. *) val pp : Format.formatter -> t -> unit (** [find ctxt k = Some v] if [v] is the value associated to [k] in @@ -606,7 +606,7 @@ module type CACHE = sig This function is based on a heuristic. The context maintains the median of the number of removed entries: this number is - multipled by `n_blocks` to determine the entries that are + multiplied by `n_blocks` to determine the entries that are likely to be removed in `n_blocks`. *) val future_cache_expectation : t -> time_in_blocks:int -> t diff --git a/src/lib_protocol_environment/sigs/v7/dal.mli b/src/lib_protocol_environment/sigs/v7/dal.mli index b1e2b016bd7fe39b997570892dafd93b4ea3e2d5..23d561e164eaacd922a03eb9ea9905327ffa17b0 100644 --- a/src/lib_protocol_environment/sigs/v7/dal.mli +++ b/src/lib_protocol_environment/sigs/v7/dal.mli @@ -84,7 +84,7 @@ val segment_proof_encoding : segment_proof Data_encoding.t (** [verify_segment t commitment segment segment_proof] returns [Ok true] if the [proof] certifies that the [slot_segment] is indeed included in the slot committed with commitment - [comitment]. Returns [Ok false] otherwise. + [commitment]. Returns [Ok false] otherwise. Fails if the index of the segment is out of range. *) val verify_segment : diff --git a/src/lib_protocol_environment/sigs/v7/data_encoding.mli b/src/lib_protocol_environment/sigs/v7/data_encoding.mli index 6e5cce210c8d1f1e07ef2bfa9baee5f31f2a416b..081b42aeb829d200e784f45d46092a08c19d6524 100644 --- a/src/lib_protocol_environment/sigs/v7/data_encoding.mli +++ b/src/lib_protocol_environment/sigs/v7/data_encoding.mli @@ -735,7 +735,7 @@ val splitted : json:'a encoding -> binary:'a encoding -> 'a encoding A stateful recursive encoding can still be put under a [delayed] combinator to make sure that a new encoding is generated each time it is used. Caching the encoding generation when the state - has not changed is then the responsability of the client. + has not changed is then the responsibility of the client. *) val mu : diff --git a/src/lib_protocol_environment/sigs/v7/list.mli b/src/lib_protocol_environment/sigs/v7/list.mli index a439fd33fb9e142c4084b5c0b0574fbdf8919f23..ff71d0bb52b9cf3c3565d8da5efc53e27bbf0c42 100644 --- a/src/lib_protocol_environment/sigs/v7/list.mli +++ b/src/lib_protocol_environment/sigs/v7/list.mli @@ -373,7 +373,7 @@ val fold_right2 : The function stops early if it encounters elements [xn], [yn] such that [f xn yn] is [false]. (This is consistent with the short-circuit, lazy - evaluation strategy of [&&] in the descritpion above.) + evaluation strategy of [&&] in the description above.) Also note that, if such an element is found in the common prefix of [xs] and [ys], then the function returns [Ok false] even if [xs] and [ys] are @@ -411,7 +411,7 @@ val for_all2 : The function stops early if it encounters elements [xn], [yn] such that [f xn yn] is [true]. (This is consistent with the short-circuit, lazy - evaluation strategy of [||] in the descritpion above.) + evaluation strategy of [||] in the description above.) Also note that, if such an element is found in the common prefix of [xs] and [ys], then the function returns [Ok true] even if [xs] and [ys] are of diff --git a/src/lib_protocol_environment/sigs/v7/lwt.mli b/src/lib_protocol_environment/sigs/v7/lwt.mli index 017303a42d9c17462ed6698299963ea05a23c4d7..3540ecae0eb2d55b6e5dce095b559dac5ed6350e 100644 --- a/src/lib_protocol_environment/sigs/v7/lwt.mli +++ b/src/lib_protocol_environment/sigs/v7/lwt.mli @@ -169,10 +169,11 @@ let () = -(** We omit [dont_wait] and other such functions because we it is only useful in - mutation-heavy loosely-synchronised code which the protocol shouldn't be. *) +(** We omit [dont_wait] and other such functions because they are only useful + in mutation-heavy loosely-synchronised code which the protocol shouldn't be. + *) -(** We omit many synchronisation primitives such as [choose] because it +(** We omit many synchronisation primitives such as [choose] because they introduce non-determinism. *) (** We omit cancelation-related primitives because we discourage Cancelation in diff --git a/src/lib_stdlib/compare.mli b/src/lib_stdlib/compare.mli index 92c7e4a7f0392a5db19fdf4ac4d6911a9ae191de..2d5b2916e63064c2c25d91274e1357bf367c9197 100644 --- a/src/lib_stdlib/compare.mli +++ b/src/lib_stdlib/compare.mli @@ -163,7 +163,7 @@ module Result (Ok : COMPARABLE) (Error : COMPARABLE) : {[ if Compare.List_length_with.(chunks > max_number_of_chunks) then - raise Maximum_size_exceeeded + raise Maximum_size_exceeded else .. ]} diff --git a/src/proto_alpha/lib_protocol/cache_repr.mli b/src/proto_alpha/lib_protocol/cache_repr.mli index 9ff2659211ca48019f9049461b952b67bb808039..f96ffdfc9d3b9815a33b3411a17ae8dcfe1e633c 100644 --- a/src/proto_alpha/lib_protocol/cache_repr.mli +++ b/src/proto_alpha/lib_protocol/cache_repr.mli @@ -72,7 +72,7 @@ module Admin : sig (** Cached values. *) type value - (** [pp fmt ctxt] is a pretty printter for the [cache] of [ctxt]. *) + (** [pp fmt ctxt] is a pretty printer for the [cache] of [ctxt]. *) val pp : Format.formatter -> Raw_context.t -> unit (** [sync ctxt ~cache_nonce] updates the context with the domain of @@ -97,7 +97,7 @@ module Admin : sig [n_blocks] are removed. This function is based on a heuristic. The context maintains the - median of the number of removed entries: this number is multipled + median of the number of removed entries: this number is multiplied by `n_blocks` to determine the entries that are likely to be removed in `n_blocks`. diff --git a/src/proto_alpha/lib_protocol/raw_context_intf.ml b/src/proto_alpha/lib_protocol/raw_context_intf.ml index 39c8b058d78aa7a682d24b1d8e9095c4cb5a2645..f4c935c2f95f0b629063d1bc0d7d1c3d112f0a0a 100644 --- a/src/proto_alpha/lib_protocol/raw_context_intf.ml +++ b/src/proto_alpha/lib_protocol/raw_context_intf.ml @@ -362,7 +362,7 @@ module type PROOF = sig [Blinded_inode h] proves that an inode with hash [h] exists in the store. - [Inode_values ls] is simliar to trees' [Node]. + [Inode_values ls] is similar to trees' [Node]. [Inode_tree i] is similar to tree's [Inode]. @@ -417,7 +417,7 @@ module type PROOF = sig (** The type for stream proofs. - The sequance [e_1 ... e_n] proves that the [e_1], ..., [e_n] are + The sequence [e_1 ... e_n] proves that the [e_1], ..., [e_n] are read in the store in sequence. *) type t = elt Seq.t end