diff options
author | Daniel de Rauglaudre <daniel.de_rauglaudre@inria.fr> | 2001-10-23 12:44:48 +0000 |
---|---|---|
committer | Daniel de Rauglaudre <daniel.de_rauglaudre@inria.fr> | 2001-10-23 12:44:48 +0000 |
commit | 7e563847718807cf309d72fcad926e2212047b42 (patch) | |
tree | 519e6b6933f0e558e05569d32dce910b85fefdfa /camlp4/ocaml_src/meta/pa_r.ml | |
parent | 65ea0ec64e9a60b7d624d47cb9026ce6d92694f3 (diff) |
-
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@3908 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'camlp4/ocaml_src/meta/pa_r.ml')
-rw-r--r-- | camlp4/ocaml_src/meta/pa_r.ml | 43 |
1 files changed, 42 insertions, 1 deletions
diff --git a/camlp4/ocaml_src/meta/pa_r.ml b/camlp4/ocaml_src/meta/pa_r.ml index b84c351fd..df5204f0a 100644 --- a/camlp4/ocaml_src/meta/pa_r.ml +++ b/camlp4/ocaml_src/meta/pa_r.ml @@ -2357,7 +2357,48 @@ Grammar.extend Grammar.Entry.obj (patt : 'patt Grammar.Entry.e), Some (Gramext.Level "simple"), [None, None, - [[Gramext.Stoken ("", "#"); + [[Gramext.Stoken ("QUESTIONIDENT", "")], + Gramext.action + (fun (i : string) (loc : int * int) -> + (MLast.PaOlb (loc, i, MLast.PaLid (loc, i), None) : 'patt)); + [Gramext.Stoken ("QUESTIONIDENTCOLON", ""); Gramext.Stoken ("", "("); + Gramext.Sself; Gramext.Stoken ("", ":"); + Gramext.Snterm (Grammar.Entry.obj (ctyp : 'ctyp Grammar.Entry.e)); + Gramext.Stoken ("", "="); + Gramext.Snterm (Grammar.Entry.obj (expr : 'expr Grammar.Entry.e)); + Gramext.Stoken ("", ")")], + Gramext.action + (fun _ (e : 'expr) _ (t : 'ctyp) _ (p : 'patt) _ (i : string) + (loc : int * int) -> + (MLast.PaOlb (loc, i, MLast.PaTyc (loc, p, t), Some e) : 'patt)); + [Gramext.Stoken ("QUESTIONIDENTCOLON", ""); Gramext.Stoken ("", "("); + Gramext.Sself; Gramext.Stoken ("", ":"); + Gramext.Snterm (Grammar.Entry.obj (ctyp : 'ctyp Grammar.Entry.e)); + Gramext.Stoken ("", ")")], + Gramext.action + (fun _ (t : 'ctyp) _ (p : 'patt) _ (i : string) (loc : int * int) -> + (MLast.PaOlb (loc, i, MLast.PaTyc (loc, p, t), None) : 'patt)); + [Gramext.Stoken ("QUESTIONIDENTCOLON", ""); Gramext.Stoken ("", "("); + Gramext.Sself; Gramext.Stoken ("", "="); + Gramext.Snterm (Grammar.Entry.obj (expr : 'expr Grammar.Entry.e)); + Gramext.Stoken ("", ")")], + Gramext.action + (fun _ (e : 'expr) _ (p : 'patt) _ (i : string) (loc : int * int) -> + (MLast.PaOlb (loc, i, p, Some e) : 'patt)); + [Gramext.Stoken ("QUESTIONIDENTCOLON", ""); Gramext.Stoken ("", "("); + Gramext.Sself; Gramext.Stoken ("", ")")], + Gramext.action + (fun _ (p : 'patt) _ (i : string) (loc : int * int) -> + (MLast.PaOlb (loc, i, p, None) : 'patt)); + [Gramext.Stoken ("TILDEIDENT", "")], + Gramext.action + (fun (i : string) (loc : int * int) -> + (MLast.PaLab (loc, i, MLast.PaLid (loc, i)) : 'patt)); + [Gramext.Stoken ("TILDEIDENTCOLON", ""); Gramext.Sself], + Gramext.action + (fun (p : 'patt) (i : string) (loc : int * int) -> + (MLast.PaLab (loc, i, p) : 'patt)); + [Gramext.Stoken ("", "#"); Gramext.Snterm (Grammar.Entry.obj (mod_ident : 'mod_ident Grammar.Entry.e))], Gramext.action |