diff --git a/.gitlab/ci/templates.yml b/.gitlab/ci/templates.yml index 312db163aaaafca0fc4e76f5be867671d0a52c29..38e508f4d10b49d771837b9635aaf9b005c10975 100644 --- a/.gitlab/ci/templates.yml +++ b/.gitlab/ci/templates.yml @@ -2,7 +2,7 @@ variables: # /!\ CI_REGISTRY is overriden to use a private Docker registry mirror in AWS ECR # in GitLab namespaces `nomadic-labs` and `tezos` ## This value MUST be the same as `opam_repository_tag` in `scripts/version.sh` - build_deps_image_version: 64153ac8d3383b21a53113a82d58ba4737b354e6 + build_deps_image_version: d23e36e7975aa9bbebbc20044a3b47f50a64e5ea build_deps_image_name: "${CI_REGISTRY}/tezos/opam-repository" GIT_STRATEGY: fetch GIT_DEPTH: "1" diff --git a/devtools/tztop/tztop_common.ml b/devtools/tztop/tztop_common.ml index 5df7e421626b1b50742e93be948164a37e84218c..f74155643d9e13744ce4a53aeef578fef6bcf32b 100644 --- a/devtools/tztop/tztop_common.ml +++ b/devtools/tztop/tztop_common.ml @@ -37,7 +37,7 @@ let patch_env_loading () = | None -> Tezos_protocol_compiler.Compiler.default_load ~unit_name let directive_string_fn fn_name = - match Hashtbl.find_opt Toploop.directive_table fn_name with + match Toploop.get_directive fn_name with | Some (Toploop.Directive_string fn) -> fn | _ -> Printf.printf diff --git a/manifest/main.ml b/manifest/main.ml index bf600537587ce0da260c5ac9c5a2e871d7a5aba2..fea2cee4d4ec6dffdaa520068159218cc813ce41 100644 --- a/manifest/main.ml +++ b/manifest/main.ml @@ -1835,7 +1835,7 @@ let tezos_protocol_compiler_lib = ~ocaml: V.( (* Should be in sync with scripts/version.sh *) - at_least "4.12.1" && less_than "4.13") + at_least "4.14.0" && less_than "4.15") ~deps: [ tezos_base |> open_ ~m:"TzPervasives"; @@ -2951,8 +2951,9 @@ end = struct (** AV0 is the Architecture Version corresponding to the first protocols. After protocol 010, some changes were made in the architecture of [lib_protocol], resulting in Architecture Version 1 (AV1). This - new version has been in effect since protocol 011. *) - type lib_protocol_architecture_version = AV0 | AV1 + new version has been in effect since protocol 011. + AV2 is in effect since protocol 014 *) + type lib_protocol_architecture_version = AV0 | AV1 | AV2 let make_tests ?test_helpers ?parameters ?plugin ?client ?benchmark ?benchmark_type_inference ~main ~environment ~name () = @@ -3187,11 +3188,12 @@ end = struct in let warnings = match template_version with - | AV0 -> "+a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68" - | AV1 -> "+a-4-40..42-44-45-48" + | AV0 -> "+a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70" + | AV1 -> "+a-4-40..42-44-45-48-51-70" + | AV2 -> "+a-4-40..42-44-45-48-70" in let warn_error = - match template_version with AV0 -> "-A" | AV1 -> "+a" + match template_version with AV0 -> "-A" | AV1 | AV2 -> "+a" in let environment = public_lib @@ -3254,10 +3256,7 @@ module CamlinternalFormatBasics = struct include CamlinternalFormatBasics end name_underscore | Alpha | V _ -> "Tezos/Protocol: economic-protocol definition") ~modules:["Protocol"] - ~warnings: - (match template_version with - | AV0 -> "+a-4-6-7-9-16-29-40..42-44-45-48-60-67-68" - | AV1 -> "+a-4-40..42-44-45-48") + ~warnings ~warn_error ~nopervasives:true ~flags_nostandard:true @@ -3350,10 +3349,7 @@ include Tezos_raw_protocol_%s.Main (* The instrumentation is removed as it can lead to a stack overflow *) (* https://gitlab.com/tezos/tezos/-/issues/1927 *) ~bisect_ppx:false - ~warnings: - (match template_version with - | AV0 -> "+a-4-6-7-9-16-29-40..42-44-45-48-60-67-68" - | AV1 -> "+a-4-40..42-44-45-48") + ~warnings ~warn_error ~nopervasives:true ~flags_nostandard:true @@ -3409,10 +3405,7 @@ include Tezos_raw_protocol_%s.Main `tezos-node`") ~modules:["Registerer"] ~linkall:true - ~warnings: - (match template_version with - | AV0 -> "+a-4-6-7-9-16-29-32-40..42-44-45-48-60-67" - | AV1 -> "+a-4-40..42-44-45-48") + ~warnings ~warn_error:"+a" ~deps:[main; tezos_protocol_updater; tezos_protocol_environment] ~dune: @@ -3519,7 +3512,9 @@ include Tezos_raw_protocol_%s.Main in let {Lib_protocol.main; embedded; environment; raw_protocol} = let template_version = - if N.(number >= 011) then Lib_protocol.AV1 else AV0 + if N.(number >= 014) then Lib_protocol.AV2 + else if N.(number >= 011) then AV1 + else AV0 in Lib_protocol.make ~template_version ~name in diff --git a/opam/tezos-protocol-compiler.opam b/opam/tezos-protocol-compiler.opam index 961878ac6a86eb5c84b06b9c4659368cb3d037b4..eaf5b270dabaf09e00b5eaeb9215ca5d16b45270 100644 --- a/opam/tezos-protocol-compiler.opam +++ b/opam/tezos-protocol-compiler.opam @@ -9,7 +9,7 @@ dev-repo: "git+https://gitlab.com/tezos/tezos.git" license: "MIT" depends: [ "dune" { >= "2.9" & < "3.0" } - "ocaml" { >= "4.12.1" & < "4.13" } + "ocaml" { >= "4.14.0" & < "4.15" } "tezos-base" "tezos-protocol-environment" "tezos-version" diff --git a/scripts/update_opam_repo.sh b/scripts/update_opam_repo.sh index f1f36ff64597729b3f671dee6ed17ea8ada0cd75..d702628d4af621230b5860d6cae261fc4b3df0fd 100755 --- a/scripts/update_opam_repo.sh +++ b/scripts/update_opam_repo.sh @@ -124,7 +124,7 @@ OPAMSOLVERTIMEOUT=600 opam admin filter --yes --resolve \ ## Adding useful compiler variants -for variant in afl flambda fp spacetime ; do +for variant in afl flambda fp ; do git checkout packages/ocaml-option-$variant/ocaml-option-$variant.1 done @@ -149,14 +149,6 @@ fi ## Adding safer hashes cp -rf packages packages.bak -# Work around a bug in opam admin 2.1 https://github.com/ocaml/opam/issues/5116, -# manually add hash for ocaml-base-compiler. -# This will no longer be necessary after we switch to ocaml.4.14. -# Indeed, the bug is triggered by the extra-source in -# https://github.com/ocaml/opam-repository/blob/master/packages/ocaml-base-compiler/ocaml-base-compiler.4.12.0/opam -# which is not present on 4.14. -sed 's/"sha256=59de25b95409c1927c4b607fb4b1218ff7623fca45474448c8e114a42853e3ad"/[\n "sha256=59de25b95409c1927c4b607fb4b1218ff7623fca45474448c8e114a42853e3ad"\n "sha512=19c7d19be804110e968866b4355871cdeb23bd4d56c18288bc0040d59702b7ee541e8bb6d49f64fa3b5a1232b50821efb50cd17544d3a2d20d760dece69e67c7"]/' -i packages/ocaml-base-compiler/ocaml-base-compiler.4.12.1/opam - opam admin add-hashes sha256 sha512 (cd "$src_dir" && dune build src/tooling/opam-lint/opam_lint.exe) diff --git a/scripts/version.sh b/scripts/version.sh index 9e47b9b4b737840c43c8d3fa89f0e7300969d3f2..8af9ae09cb661b879b46864f7724119f1e60cf77 100755 --- a/scripts/version.sh +++ b/scripts/version.sh @@ -13,7 +13,7 @@ ## This script is also sourced in the Makefile, as such it should be compatible ## with both the make and sh syntax -export ocaml_version=4.12.1 +export ocaml_version=4.14.0 export opam_version=2 export recommended_rust_version=1.52.1 export recommended_node_version=14.12.0 @@ -25,7 +25,7 @@ export full_opam_repository_tag=3dbade647e4d2d38094e43ed33626d4b5be305bb ## opam_repository is an additional, tezos-specific opam repository. ## This value MUST be the same as `build_deps_image_version` in `.gitlab/ci/templates.yml export opam_repository_url=https://gitlab.com/tezos/opam-repository -export opam_repository_tag=64153ac8d3383b21a53113a82d58ba4737b354e6 +export opam_repository_tag=d23e36e7975aa9bbebbc20044a3b47f50a64e5ea export opam_repository_git=$opam_repository_url.git export opam_repository=$opam_repository_git\#$opam_repository_tag diff --git a/src/lib_protocol_compiler/compiler.ml b/src/lib_protocol_compiler/compiler.ml index 35952cd49fe3074d03882ca7e6aadcc46d3640b8..e05f95340ec9b2c27649538bee8ca3529e104149 100644 --- a/src/lib_protocol_compiler/compiler.ml +++ b/src/lib_protocol_compiler/compiler.ml @@ -279,8 +279,11 @@ let main {compile_ml; pack_objects; link_shared} = Clflags.nopervasives := true ; Clflags.no_std_include := true ; Clflags.include_dirs := [Filename.dirname functor_file] ; - Warnings.parse_options false warnings ; - Warnings.parse_options true warn_error ; + let parse_options errflag s = + Option.iter Location.(prerr_alert none) (Warnings.parse_options errflag s) + in + parse_options false warnings ; + parse_options true warn_error ; load_embedded_cmis tezos_protocol_env ; let packed_protocol_object = compile_ml ~for_pack functor_file in let register_objects = diff --git a/src/lib_webassembly/interpreter/dune.inc b/src/lib_webassembly/interpreter/dune.inc index 652dfc9326a3c1f31f14b3b318e2fe0bd41ed930..861dd3364be046d44a2244378db67368328cc3b2 100644 --- a/src/lib_webassembly/interpreter/dune.inc +++ b/src/lib_webassembly/interpreter/dune.inc @@ -18,7 +18,7 @@ (env (_ (flags - (-w +a-4-27-42-44-45 -warn-error +a-3)))) + (-w +a-4-27-42-44-45-69-70 -warn-error +a-3)))) (rule ; Run the WebAssembly core tests. diff --git a/src/proto_000_Ps9mPmXa/lib_protocol/dune b/src/proto_000_Ps9mPmXa/lib_protocol/dune index 8ce3ef4a951a21578f91fa9062df73497b5491d1..b7f69584b6e792bfc517d4c6982ccfc2ae51baf7 100644 --- a/src/proto_000_Ps9mPmXa/lib_protocol/dune +++ b/src/proto_000_Ps9mPmXa/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -44,7 +44,7 @@ tezos-protocol-environment.sigs tezos-protocol-000-Ps9mPmXa.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -90,7 +90,7 @@ tezos-protocol-environment.sigs tezos-protocol-000-Ps9mPmXa.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -118,7 +118,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_001_PtCJ7pwo/lib_protocol/dune b/src/proto_001_PtCJ7pwo/lib_protocol/dune index bb9877b72bef0fb84b6f9741e801800bc0b8de02..aaf13e5bd565547965df12565f697e34cf3a1b9d 100644 --- a/src/proto_001_PtCJ7pwo/lib_protocol/dune +++ b/src/proto_001_PtCJ7pwo/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -111,7 +111,7 @@ tezos-protocol-environment.sigs tezos-protocol-001-PtCJ7pwo.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -288,7 +288,7 @@ tezos-protocol-environment.sigs tezos-protocol-001-PtCJ7pwo.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -381,7 +381,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_002_PsYLVpVv/lib_protocol/dune b/src/proto_002_PsYLVpVv/lib_protocol/dune index dbbdab1b90045a9583e1afe481f00deb3179c850..86299ac909f9d8f2bcc5a2d0d896fed9c86be09a 100644 --- a/src/proto_002_PsYLVpVv/lib_protocol/dune +++ b/src/proto_002_PsYLVpVv/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -111,7 +111,7 @@ tezos-protocol-environment.sigs tezos-protocol-002-PsYLVpVv.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -288,7 +288,7 @@ tezos-protocol-environment.sigs tezos-protocol-002-PsYLVpVv.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -381,7 +381,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_003_PsddFKi3/lib_protocol/dune b/src/proto_003_PsddFKi3/lib_protocol/dune index 6aa1e078d6cf517fd98af49929c292d3ad7daee8..9ab17c831adcb3d03512b6e92a3cf840eac21adb 100644 --- a/src/proto_003_PsddFKi3/lib_protocol/dune +++ b/src/proto_003_PsddFKi3/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -112,7 +112,7 @@ tezos-protocol-environment.sigs tezos-protocol-003-PsddFKi3.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -291,7 +291,7 @@ tezos-protocol-environment.sigs tezos-protocol-003-PsddFKi3.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -385,7 +385,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_004_Pt24m4xi/lib_protocol/dune b/src/proto_004_Pt24m4xi/lib_protocol/dune index 4f41b3e45ddaf8e7791739280a4226a3e50cf4b7..f490289b631898465ddc6c71d7f736760005c70e 100644 --- a/src/proto_004_Pt24m4xi/lib_protocol/dune +++ b/src/proto_004_Pt24m4xi/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -112,7 +112,7 @@ tezos-protocol-environment.sigs tezos-protocol-004-Pt24m4xi.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -291,7 +291,7 @@ tezos-protocol-environment.sigs tezos-protocol-004-Pt24m4xi.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -385,7 +385,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_005_PsBABY5H/lib_protocol/dune b/src/proto_005_PsBABY5H/lib_protocol/dune index 4f1ef44c04000a98f02562c39d29bdbddb9689cd..93a1d8d4a83a26f0eb555b07a09f14d94d5ffe17 100644 --- a/src/proto_005_PsBABY5H/lib_protocol/dune +++ b/src/proto_005_PsBABY5H/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -113,7 +113,7 @@ tezos-protocol-environment.sigs tezos-protocol-005-PsBABY5H.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -294,7 +294,7 @@ tezos-protocol-environment.sigs tezos-protocol-005-PsBABY5H.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -389,7 +389,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_005_PsBabyM1/lib_protocol/dune b/src/proto_005_PsBabyM1/lib_protocol/dune index c9f2fc4858e3c8da7399e5091b9e4cb14e89eafc..193d7a913064b671afb07ac718db74550bf7daf1 100644 --- a/src/proto_005_PsBabyM1/lib_protocol/dune +++ b/src/proto_005_PsBabyM1/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -113,7 +113,7 @@ tezos-protocol-environment.sigs tezos-protocol-005-PsBabyM1.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -294,7 +294,7 @@ tezos-protocol-environment.sigs tezos-protocol-005-PsBabyM1.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -389,7 +389,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_006_PsCARTHA/lib_protocol/dune b/src/proto_006_PsCARTHA/lib_protocol/dune index 6281cbffc01d8d4b82ffe320a1ebe7640f0707f4..071c7f8c7bc539af22e2900fb2a3802c26a91aa2 100644 --- a/src/proto_006_PsCARTHA/lib_protocol/dune +++ b/src/proto_006_PsCARTHA/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -113,7 +113,7 @@ tezos-protocol-environment.sigs tezos-protocol-006-PsCARTHA.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -294,7 +294,7 @@ tezos-protocol-environment.sigs tezos-protocol-006-PsCARTHA.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -389,7 +389,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_007_PsDELPH1/lib_protocol/dune b/src/proto_007_PsDELPH1/lib_protocol/dune index 6e410dc223decc5ae5f086c66e807a2d02bd40b5..7617c535c5ea578556cafcccbf0503f4a82d7cfe 100644 --- a/src/proto_007_PsDELPH1/lib_protocol/dune +++ b/src/proto_007_PsDELPH1/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -115,7 +115,7 @@ tezos-protocol-environment.sigs tezos-protocol-007-PsDELPH1.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -300,7 +300,7 @@ tezos-protocol-environment.sigs tezos-protocol-007-PsDELPH1.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -397,7 +397,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_008_PtEdo2Zk/lib_protocol/dune b/src/proto_008_PtEdo2Zk/lib_protocol/dune index fc601257c5c5be04b0309db29265a82930a88c30..1977601ff02c6d31c978a41e97d800bac00dcb61 100644 --- a/src/proto_008_PtEdo2Zk/lib_protocol/dune +++ b/src/proto_008_PtEdo2Zk/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -120,7 +120,7 @@ tezos-protocol-environment.sigs tezos-protocol-008-PtEdo2Zk.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -315,7 +315,7 @@ tezos-protocol-environment.sigs tezos-protocol-008-PtEdo2Zk.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -417,7 +417,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_008_PtEdoTez/lib_protocol/dune b/src/proto_008_PtEdoTez/lib_protocol/dune index 9034602f3769938af49eeaebe0fabcd06b136078..94cb0b65fb6320c1a8ae643c5e5407f5867b0e3b 100644 --- a/src/proto_008_PtEdoTez/lib_protocol/dune +++ b/src/proto_008_PtEdoTez/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -120,7 +120,7 @@ tezos-protocol-environment.sigs tezos-protocol-008-PtEdoTez.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -315,7 +315,7 @@ tezos-protocol-environment.sigs tezos-protocol-008-PtEdoTez.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -417,7 +417,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_009_PsFLoren/lib_protocol/dune b/src/proto_009_PsFLoren/lib_protocol/dune index 74ae595f594826064b086320e5bb69461ec53edb..d75ffcc3d8e561cfd7a98adcb7dd9fdc58fb5956 100644 --- a/src/proto_009_PsFLoren/lib_protocol/dune +++ b/src/proto_009_PsFLoren/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -123,7 +123,7 @@ tezos-protocol-environment.sigs tezos-protocol-009-PsFLoren.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -324,7 +324,7 @@ tezos-protocol-environment.sigs tezos-protocol-009-PsFLoren.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -429,7 +429,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_010_PtGRANAD/lib_protocol/dune b/src/proto_010_PtGRANAD/lib_protocol/dune index 41a19845e60c36b116b838d1d991e1fffd339cfb..02bc07cccbe5a0ca5b87eabdeeb4e5c0ec3fce58 100644 --- a/src/proto_010_PtGRANAD/lib_protocol/dune +++ b/src/proto_010_PtGRANAD/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -128,7 +128,7 @@ tezos-protocol-environment.sigs tezos-protocol-010-PtGRANAD.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -339,7 +339,7 @@ tezos-protocol-environment.sigs tezos-protocol-010-PtGRANAD.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -449,7 +449,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_011_PtHangz2/lib_protocol/dune b/src/proto_011_PtHangz2/lib_protocol/dune index 4da4e14782eeb88c4d0126b92ce10bdc1540ec1f..66ee5aced61feabf6cac972abd2d804802dd02b6 100644 --- a/src/proto_011_PtHangz2/lib_protocol/dune +++ b/src/proto_011_PtHangz2/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a -nostdlib -nopervasives @@ -140,7 +140,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-011-PtHangz2.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Protocol)) @@ -376,7 +376,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-011-PtHangz2.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Functor)) @@ -498,7 +498,7 @@ tezos-protocol-environment) (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_012_Psithaca/lib_protocol/dune b/src/proto_012_Psithaca/lib_protocol/dune index 853ec2bf6676e96e4667f118397004d2df21da35..d689fca95d490fa07380abd0fd740b123da8bda9 100644 --- a/src/proto_012_Psithaca/lib_protocol/dune +++ b/src/proto_012_Psithaca/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a -nostdlib -nopervasives @@ -157,7 +157,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-012-Psithaca.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Protocol)) @@ -427,7 +427,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-012-Psithaca.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Functor)) @@ -566,7 +566,7 @@ tezos-protocol-environment) (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_013_PtJakart/lib_protocol/dune b/src/proto_013_PtJakart/lib_protocol/dune index a8535c1b78135fca79b9c9d79e10a3940ef4a850..2918010fc563cb19e00e5afbfd22a68d86335e5b 100644 --- a/src/proto_013_PtJakart/lib_protocol/dune +++ b/src/proto_013_PtJakart/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a -nostdlib -nopervasives @@ -222,7 +222,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-013-PtJakart.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Protocol)) @@ -624,7 +624,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-013-PtJakart.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Functor)) @@ -829,7 +829,7 @@ tezos-protocol-environment) (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_013_PtJakart/lib_protocol/test/integration/operations/test_tx_rollup.ml b/src/proto_013_PtJakart/lib_protocol/test/integration/operations/test_tx_rollup.ml index 75aa3f939b8828d17a4b6a0c52132a22b4fadd01..f2e40475264beb9490ef9b3e1aa666186c65a1b2 100644 --- a/src/proto_013_PtJakart/lib_protocol/test/integration/operations/test_tx_rollup.ml +++ b/src/proto_013_PtJakart/lib_protocol/test/integration/operations/test_tx_rollup.ml @@ -3138,12 +3138,12 @@ module Rejection = struct >>=? fun _ -> return_unit (** Drop the last element of a seq, that is, the last element of a proof *) - let rec drop x = + let rec drop_last x = let open Seq in match x with | Cons (x, xs) -> ( let node = xs () in - match node with Nil -> Nil | n -> Cons (x, fun () -> drop n)) + match node with Nil -> Nil | n -> Cons (x, fun () -> drop_last n)) | Nil -> assert false let test_valid_proof_truncated () = @@ -3173,7 +3173,7 @@ module Rejection = struct make_proof store l2_parameters deposit >>= fun proof -> let proof_truncated = let proof_node = proof.state () in - let truncated_node = drop proof_node in + let truncated_node = drop_last proof_node in {proof with state = (fun () -> truncated_node)} in (* We try to reject with the truncated proof which is already above the diff --git a/src/proto_alpha/lib_protocol/dune b/src/proto_alpha/lib_protocol/dune index d67ff7c0e3f479d5f68835d2f0344ceb72a85495..73761c300e8d123fe76ffe14f3e3337e7506eece 100644 --- a/src/proto_alpha/lib_protocol/dune +++ b/src/proto_alpha/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-70 -warn-error +a -nostdlib -nopervasives @@ -232,7 +232,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-alpha.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-70 -warn-error +a -nopervasives)) (modules Protocol)) @@ -655,7 +655,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-alpha.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-70 -warn-error +a -nopervasives)) (modules Functor)) @@ -871,7 +871,7 @@ tezos-protocol-environment) (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_alpha/lib_protocol/global_constants_storage.ml b/src/proto_alpha/lib_protocol/global_constants_storage.ml index 7de7c9479df89ceff9449b16223c806260eafa12..f00b2f3330c512b46578e8d1d399acd0d66d7ee7 100644 --- a/src/proto_alpha/lib_protocol/global_constants_storage.ml +++ b/src/proto_alpha/lib_protocol/global_constants_storage.ml @@ -42,18 +42,18 @@ let bottom_up_fold_cps initial_accumulator node initial_k f = match node with | String _ | Int _ | Bytes _ -> k accu node | Prim (loc, prim, args, annot) -> - (traverse_nodes [@ocaml.tailcall]) accu args @@ fun accu args -> - f accu (Prim (loc, prim, args, annot)) k + (traverse_nodes [@ocaml.tailcall]) accu args (fun accu args -> + f accu (Prim (loc, prim, args, annot)) k) | Seq (loc, elts) -> - (traverse_nodes [@ocaml.tailcall]) accu elts @@ fun accu elts -> - f accu (Seq (loc, elts)) k + (traverse_nodes [@ocaml.tailcall]) accu elts (fun accu elts -> + f accu (Seq (loc, elts)) k) and traverse_nodes accu nodes k = match nodes with | [] -> k accu [] | node :: nodes -> - (traverse_node [@ocaml.tailcall]) accu node @@ fun accu node -> - (traverse_nodes [@ocaml.tailcall]) accu nodes @@ fun accu nodes -> - k accu (node :: nodes) + (traverse_node [@ocaml.tailcall]) accu node (fun accu node -> + (traverse_nodes [@ocaml.tailcall]) accu nodes (fun accu nodes -> + k accu (node :: nodes))) in traverse_node initial_accumulator node initial_k [@@coq_axiom_with_reason "local mutually recursive definition not handled"] diff --git a/src/proto_alpha/lib_protocol/script_typed_ir.ml b/src/proto_alpha/lib_protocol/script_typed_ir.ml index dd097f86a2320d26edda223490d229c100d5c1f6..ace9d41489774034b5cd8dee83e6a87885e22589 100644 --- a/src/proto_alpha/lib_protocol/script_typed_ir.ml +++ b/src/proto_alpha/lib_protocol/script_typed_ir.ml @@ -2010,19 +2010,19 @@ let kinstr_traverse i init f = fun accu t continue -> let accu = f.apply accu t in let next k = - (aux [@ocaml.tailcall]) accu k @@ fun accu -> - (continue [@ocaml.tailcall]) accu + (aux [@ocaml.tailcall]) accu k (fun accu -> + (continue [@ocaml.tailcall]) accu) in let next2 k1 k2 = - (aux [@ocaml.tailcall]) accu k1 @@ fun accu -> - (aux [@ocaml.tailcall]) accu k2 @@ fun accu -> - (continue [@ocaml.tailcall]) accu + (aux [@ocaml.tailcall]) accu k1 (fun accu -> + (aux [@ocaml.tailcall]) accu k2 (fun accu -> + (continue [@ocaml.tailcall]) accu)) in let next3 k1 k2 k3 = - (aux [@ocaml.tailcall]) accu k1 @@ fun accu -> - (aux [@ocaml.tailcall]) accu k2 @@ fun accu -> - (aux [@ocaml.tailcall]) accu k3 @@ fun accu -> - (continue [@ocaml.tailcall]) accu + (aux [@ocaml.tailcall]) accu k1 (fun accu -> + (aux [@ocaml.tailcall]) accu k2 (fun accu -> + (aux [@ocaml.tailcall]) accu k3 (fun accu -> + (continue [@ocaml.tailcall]) accu))) in let return () = (continue [@ocaml.tailcall]) accu in match t with @@ -2214,13 +2214,13 @@ let ty_traverse = (next2 [@ocaml.tailcall]) f accu ty1 ty2 continue | Option_t (ty1, _, _) -> (next [@ocaml.tailcall]) f accu ty1 continue | List_t (ty1, _) -> (next [@ocaml.tailcall]) f accu ty1 continue - | Set_t (cty, _) -> (aux [@ocaml.tailcall]) f accu cty @@ continue + | Set_t (cty, _) -> (aux [@ocaml.tailcall]) f accu cty continue | Map_t (cty, ty1, _) -> - (aux [@ocaml.tailcall]) f accu cty @@ fun accu -> - (next [@ocaml.tailcall]) f accu ty1 continue + (aux [@ocaml.tailcall]) f accu cty (fun accu -> + (next [@ocaml.tailcall]) f accu ty1 continue) | Big_map_t (cty, ty1, _) -> - (aux [@ocaml.tailcall]) f accu cty @@ fun accu -> - (next [@ocaml.tailcall]) f accu ty1 continue + (aux [@ocaml.tailcall]) f accu cty (fun accu -> + (next [@ocaml.tailcall]) f accu ty1 continue) | Contract_t (ty1, _) -> (next [@ocaml.tailcall]) f accu ty1 continue and next2 : type a ac b bc ret accu. @@ -2231,15 +2231,15 @@ let ty_traverse = (accu -> ret) -> ret = fun f accu ty1 ty2 continue -> - (aux [@ocaml.tailcall]) f accu ty1 @@ fun accu -> - (aux [@ocaml.tailcall]) f accu ty2 @@ fun accu -> - (continue [@ocaml.tailcall]) accu + (aux [@ocaml.tailcall]) f accu ty1 (fun accu -> + (aux [@ocaml.tailcall]) f accu ty2 (fun accu -> + (continue [@ocaml.tailcall]) accu)) and next : type a ac ret accu. accu ty_traverse -> accu -> (a, ac) ty -> (accu -> ret) -> ret = fun f accu ty1 continue -> - (aux [@ocaml.tailcall]) f accu ty1 @@ fun accu -> - (continue [@ocaml.tailcall]) accu + (aux [@ocaml.tailcall]) f accu ty1 (fun accu -> + (continue [@ocaml.tailcall]) accu) in fun ty init f -> aux f init ty (fun accu -> accu) @@ -2264,20 +2264,20 @@ let value_traverse (type t tc) (ty : (t, tc) ty) (x : t) init f = fun accu ty x continue -> let accu = f.apply accu ty x in let next2 ty1 ty2 x1 x2 = - (aux [@ocaml.tailcall]) accu ty1 x1 @@ fun accu -> - (aux [@ocaml.tailcall]) accu ty2 x2 @@ fun accu -> - (continue [@ocaml.tailcall]) accu + (aux [@ocaml.tailcall]) accu ty1 x1 (fun accu -> + (aux [@ocaml.tailcall]) accu ty2 x2 (fun accu -> + (continue [@ocaml.tailcall]) accu)) in let next ty1 x1 = - (aux [@ocaml.tailcall]) accu ty1 x1 @@ fun accu -> - (continue [@ocaml.tailcall]) accu + (aux [@ocaml.tailcall]) accu ty1 x1 (fun accu -> + (continue [@ocaml.tailcall]) accu) in let return () = (continue [@ocaml.tailcall]) accu in let rec on_list ty' accu = function | [] -> (continue [@ocaml.tailcall]) accu | x :: xs -> - (aux [@ocaml.tailcall]) accu ty' x @@ fun accu -> - (on_list [@ocaml.tailcall]) ty' accu xs + (aux [@ocaml.tailcall]) accu ty' x (fun accu -> + (on_list [@ocaml.tailcall]) ty' accu xs) in match ty with | Unit_t | Int_t | Nat_t | Signature_t | String_t | Bytes_t | Mutez_t @@ -2324,9 +2324,9 @@ let value_traverse (type t tc) (ty : (t, tc) ty) (x : t) init f = match xs with | [] -> (continue [@ocaml.tailcall]) accu | (k, v) :: xs -> - (aux [@ocaml.tailcall]) accu kty k @@ fun accu -> - (aux [@ocaml.tailcall]) accu ty' v @@ fun accu -> - (on_bindings [@ocaml.tailcall]) accu kty ty' continue xs + (aux [@ocaml.tailcall]) accu kty k (fun accu -> + (aux [@ocaml.tailcall]) accu ty' v (fun accu -> + (on_bindings [@ocaml.tailcall]) accu kty ty' continue xs)) in aux init ty x (fun accu -> accu) [@@coq_axiom_with_reason "local mutually recursive definition not handled"] diff --git a/src/proto_alpha/lib_protocol/test/integration/operations/test_tx_rollup.ml b/src/proto_alpha/lib_protocol/test/integration/operations/test_tx_rollup.ml index e1dc02698636a1b886a2c2acd6ebf8cac6a4b52b..bee71cc51eab0bce327e0fff7b6cd0371779d213 100644 --- a/src/proto_alpha/lib_protocol/test/integration/operations/test_tx_rollup.ml +++ b/src/proto_alpha/lib_protocol/test/integration/operations/test_tx_rollup.ml @@ -3193,15 +3193,15 @@ module Rejection = struct >>=? fun _ -> return_unit (** Drop the last element of a seq, that is, the last element of a proof *) - let rec drop x = + let rec drop_last x = let open Seq in match x with | Cons (x, xs) -> ( let node = xs () in - match node with Nil -> Nil | n -> Cons (x, fun () -> drop n)) + match node with Nil -> Nil | n -> Cons (x, fun () -> drop_last n)) | Nil -> assert false - let rec drop_n x n = if n <= 0 then x else drop_n (drop x) (n - 1) + let rec drop_n x n = if n <= 0 then x else drop_n (drop_last x) (n - 1) let test_valid_proof_truncated () = let _, _, addr = gen_l2_account () in @@ -3226,7 +3226,7 @@ module Rejection = struct make_proof store l2_parameters deposit >>= fun proof -> let proof_truncated = let proof_node = proof.state () in - let truncated_node = drop proof_node in + let truncated_node = drop_last proof_node in {proof with state = (fun () -> truncated_node)} in (* We try to reject with the truncated proof which is already above the diff --git a/src/proto_alpha/lib_protocol/tx_rollup_gas.ml b/src/proto_alpha/lib_protocol/tx_rollup_gas.ml index 41857f1c03e789c2e803315d612a54253eddbcaf..77c60ec8229b62b7f75bd08a5220e54b8f019cae 100644 --- a/src/proto_alpha/lib_protocol/tx_rollup_gas.ml +++ b/src/proto_alpha/lib_protocol/tx_rollup_gas.ml @@ -41,7 +41,7 @@ let hash_cost input_size = let cost_blake2b = Gas_limit_repr.atomic_step_cost cost_N_IBlake2b in ok @@ (cost_serialization + cost_blake2b) -(** Model from {!Ticket_costs.cost_compare_ticket_hash} since they are +(** Model from {!Ticket_costs.Constants.cost_compare_ticket_hash} since they are Blake2B hashes too. *) let compare_blake2b_hash = S.safe_int 10 diff --git a/src/proto_demo_counter/lib_protocol/dune b/src/proto_demo_counter/lib_protocol/dune index 537397a514961e74726e3ed18050517ca5fb378c..b9108abef9b4c5789077e335d554832a92847714 100644 --- a/src/proto_demo_counter/lib_protocol/dune +++ b/src/proto_demo_counter/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a -nostdlib -nopervasives @@ -52,7 +52,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-demo-counter.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Protocol)) @@ -112,7 +112,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-demo-counter.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Functor)) @@ -146,7 +146,7 @@ tezos-protocol-environment) (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_demo_noops/lib_protocol/dune b/src/proto_demo_noops/lib_protocol/dune index 64de0c716f550c1385c0a7e944934c50434318ee..b0f7a965c08cd326df7ad60d51bde5ec8e0ed173 100644 --- a/src/proto_demo_noops/lib_protocol/dune +++ b/src/proto_demo_noops/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a -nostdlib -nopervasives @@ -43,7 +43,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-demo-noops.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Protocol)) @@ -83,7 +83,7 @@ tezos-protocol-environment tezos-protocol-environment.sigs tezos-protocol-demo-noops.raw) - (flags (-w +a-4-40..42-44-45-48 + (flags (-w +a-4-40..42-44-45-48-51-70 -warn-error +a -nopervasives)) (modules Functor)) @@ -108,7 +108,7 @@ tezos-protocol-environment) (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-40..42-44-45-48 + -w +a-4-40..42-44-45-48-51-70 -warn-error +a)) (modules Registerer)) diff --git a/src/proto_genesis/lib_protocol/dune b/src/proto_genesis/lib_protocol/dune index d751b1a66f26f9209d977469017bdc4b4c905c57..935586a099b1b9c3ad7b67dad9bc4cfc22903bc4 100644 --- a/src/proto_genesis/lib_protocol/dune +++ b/src/proto_genesis/lib_protocol/dune @@ -26,7 +26,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67-68 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a -nostdlib -nopervasives @@ -44,7 +44,7 @@ tezos-protocol-environment.sigs tezos-protocol-genesis.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Protocol)) @@ -89,7 +89,7 @@ tezos-protocol-environment.sigs tezos-protocol-genesis.raw) (flags - (-w +a-4-6-7-9-16-29-40..42-44-45-48-60-67-68 + (-w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error -A -nopervasives)) (modules Functor)) @@ -117,7 +117,7 @@ (library_flags (:standard -linkall)) (flags (:standard - -w +a-4-6-7-9-16-29-32-40..42-44-45-48-60-67 + -w +a-4-6-7-9-16-29-32-40..42-44-45-48-51-60-67-68-70 -warn-error +a)) (modules Registerer))