diff options
| author | Pierre-Marie Pédrot | 2018-10-04 11:18:02 +0200 |
|---|---|---|
| committer | Pierre-Marie Pédrot | 2018-10-04 11:18:02 +0200 |
| commit | 8a5cb2d9da73b94e1713f5ee6cba73e0680f20fb (patch) | |
| tree | b66c100bb04261b43970d630b1cbf30b552fe90a /plugins/extraction/common.ml | |
| parent | 79da82da057224eec8abaf96c20b0725f18b2945 (diff) | |
| parent | 87d5e79baea4f3679a1429d2a2e128b564eec5d5 (diff) | |
Merge PR #8626: [ocaml] [lib] Remove some compatibility layers for OCaml < 4.03.0
Diffstat (limited to 'plugins/extraction/common.ml')
| -rw-r--r-- | plugins/extraction/common.ml | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/plugins/extraction/common.ml b/plugins/extraction/common.ml index f235bb8986..d413cd1e6d 100644 --- a/plugins/extraction/common.ml +++ b/plugins/extraction/common.ml @@ -112,17 +112,12 @@ let pseudo_qualify = qualify "__" let is_upper s = match s.[0] with 'A' .. 'Z' -> true | _ -> false let is_lower s = match s.[0] with 'a' .. 'z' | '_' -> true | _ -> false -[@@@ocaml.warning "-3"] (* String.(un)capitalize_ascii since 4.03.0 GPR#124 *) -let capitalize = String.capitalize -let uncapitalize = String.uncapitalize -[@@@ocaml.warning "+3"] - -let lowercase_id id = Id.of_string (uncapitalize (ascii_of_id id)) +let lowercase_id id = Id.of_string (String.uncapitalize_ascii (ascii_of_id id)) let uppercase_id id = let s = ascii_of_id id in assert (not (String.is_empty s)); if s.[0] == '_' then Id.of_string ("Coq_"^s) - else Id.of_string (capitalize s) + else Id.of_string (String.capitalize_ascii s) type kind = Term | Type | Cons | Mod |
