diff options
-rw-r--r-- | camlp4/etc/pa_o.ml | 8 | ||||
-rw-r--r-- | camlp4/ocaml_src/camlp4/ast2pt.ml | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/camlp4/etc/pa_o.ml b/camlp4/etc/pa_o.ml index cc9153625..4f27f5ecc 100644 --- a/camlp4/etc/pa_o.ml +++ b/camlp4/etc/pa_o.ml @@ -1151,13 +1151,13 @@ EXTEND ctyp: LEVEL "arrow" [ RIGHTA [ i = lident_colon; t1 = ctyp LEVEL "star"; "->"; t2 = SELF -> - <:ctyp< ~ $i$ : $t1$ -> $t2$ >> + <:ctyp< ( ~ $i$ : $t1$ ) -> $t2$ >> | i = OPTLABEL; t1 = ctyp LEVEL "star"; "->"; t2 = SELF -> - <:ctyp< ? $i$ : $t1$ -> $t2$ >> + <:ctyp< ( ? $i$ : $t1$ ) -> $t2$ >> | i = QUESTIONIDENT; ":"; t1 = ctyp LEVEL "star"; "->"; t2 = SELF -> - <:ctyp< ? $i$ : $t1$ -> $t2$ >> + <:ctyp< ( ? $i$ : $t1$ ) -> $t2$ >> | "?"; i=lident_colon;t1 = ctyp LEVEL "star"; "->"; t2 = SELF -> - <:ctyp< ? $i$ : $t1$ -> $t2$ >> ] ] + <:ctyp< ( ? $i$ : $t1$ ) -> $t2$ >> ] ] ; ctyp: LEVEL "simple" [ [ "["; OPT "|"; rfl = LIST1 row_field SEP "|"; "]" -> diff --git a/camlp4/ocaml_src/camlp4/ast2pt.ml b/camlp4/ocaml_src/camlp4/ast2pt.ml index d742b5563..6839428ea 100644 --- a/camlp4/ocaml_src/camlp4/ast2pt.ml +++ b/camlp4/ocaml_src/camlp4/ast2pt.ml @@ -169,10 +169,10 @@ let rec ctyp = | TyObj (loc, fl, v) -> mktyp loc (Ptyp_object (meth_list loc fl v)) | TyCls (loc, id) -> mktyp loc (Ptyp_class (long_id_of_string_list loc id, [], [])) - | TyLab (loc, _, _) -> error loc "labeled type not allowed here" + | TyLab (loc, _, _) -> error loc "labelled type not allowed here" | TyLid (loc, s) -> mktyp loc (Ptyp_constr (lident s, [])) - | TyMan (loc, _, _) -> error loc "type manifest not allowed here" - | TyOlb (loc, lab, _) -> error loc "labeled type not allowed here" + | TyMan (loc, _, _) -> error loc "manifest type not allowed here" + | TyOlb (loc, lab, _) -> error loc "labelled type not allowed here" | TyPol (loc, pl, t) -> mktyp loc (Ptyp_poly (pl, ctyp t)) | TyQuo (loc, s) -> mktyp loc (Ptyp_var s) | TyRec (loc, _, _) -> error loc "record type not allowed here" |