--- ./extend_helper.ml +++ ./extend_helper.ml @@ -1,13 +1,6 @@ -(*pp cppo -V OCAML:`ocamlc -version` *) open Parsetree open Extend_protocol -#if OCAML_VERSION < (4, 3, 0) -# define CONST_STRING Asttypes.Const_string -#else -# define CONST_STRING Parsetree.Pconst_string -#endif - (** Default implementation for [Reader_def.print_outcome] using [Oprint] from compiler-libs *) let print_outcome_using_oprint ppf = function @@ -28,7 +21,7 @@ pstr_loc = Location.none; pstr_desc = Pstr_eval ({ pexp_loc = Location.none; - pexp_desc = Pexp_constant (CONST_STRING (msg, None)); + pexp_desc = Pexp_constant (Parsetree.Pconst_string (msg, None)); pexp_attributes = []; }, []); }] @@ -112,7 +105,7 @@ let msg = match payload with | PStr [{ pstr_desc = Pstr_eval ({ - pexp_desc = Pexp_constant (CONST_STRING (msg, _)); + pexp_desc = Pexp_constant (Parsetree.Pconst_string (msg, _)); }, _); }] -> msg | _ -> "Warning: extension produced an incorrect syntax-error node"