summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavier Clerc <xavier.clerc@inria.fr>2011-06-06 07:04:42 +0000
committerXavier Clerc <xavier.clerc@inria.fr>2011-06-06 07:04:42 +0000
commit075d3eb59d8dfb97cbb63aed8c6183737681f4bc (patch)
treebe7501416dfd7c36ffcae8333c3fb6e9db41272a
parentb687f933f39c6e18c2b2680f23bcb0fac7a19cf8 (diff)
downloadocaml-075d3eb59d8dfb97cbb63aed8c6183737681f4bc.tar.gz
Fixes the regression discussed in the notes of PR#5080.
git-svn-id: http://caml.inria.fr/svn/ocaml/version/3.12@11070 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
-rw-r--r--camlp4/Camlp4Parsers/Camlp4MacroParser.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/camlp4/Camlp4Parsers/Camlp4MacroParser.ml b/camlp4/Camlp4Parsers/Camlp4MacroParser.ml
index df261e99b7..0cb81be945 100644
--- a/camlp4/Camlp4Parsers/Camlp4MacroParser.ml
+++ b/camlp4/Camlp4Parsers/Camlp4MacroParser.ml
@@ -406,13 +406,13 @@ module Make (Syntax : Sig.Camlp4Syntax) = struct
[ [ i = UIDENT -> i ] ]
;
(* dirty hack to allow polymorphic variants using the introduced keywords. *)
- expr: LEVEL "~-"
+ expr: BEFORE "simple"
[ [ "`"; kwd = [ "IFDEF" | "IFNDEF" | "THEN" | "ELSE" | "END" | "ENDIF"
| "DEFINE" | "IN" ] -> <:expr< `$uid:kwd$ >>
| "`"; s = a_ident -> <:expr< ` $s$ >> ] ]
;
(* idem *)
- patt: LEVEL "apply"
+ patt: BEFORE "simple"
[ [ "`"; kwd = [ "IFDEF" | "IFNDEF" | "THEN" | "ELSE" | "END" | "ENDIF" ] ->
<:patt< `$uid:kwd$ >>
| "`"; s = a_ident -> <:patt< ` $s$ >> ] ]