[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 2/5] parser: use api.pure full
From: |
Akim Demaille |
Subject: |
[PATCH 2/5] parser: use api.pure full |
Date: |
Mon, 4 Feb 2013 16:50:05 +0100 |
* src/parse-gram.y: Use api.pure full instead of silly macro tricks.
---
src/parse-gram.y | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/src/parse-gram.y b/src/parse-gram.y
index 0b42004..a509435 100644
--- a/src/parse-gram.y
+++ b/src/parse-gram.y
@@ -44,13 +44,9 @@ static YYLTYPE lloc_default (YYLTYPE const *, int);
static void version_check (location const *loc, char const *version);
-/* Request detailed syntax error messages, and pass them to GRAM_ERROR.
- FIXME: depends on the undocumented availability of YYLLOC. */
-#undef yyerror
-#define yyerror(Msg) \
- gram_error (&yylloc, Msg)
static void gram_error (location const *, char const *);
+/// A string that describes a char (e.g., 'a' -> "'a'").
static char const *char_name (char);
%}
@@ -88,7 +84,7 @@ static char const *char_name (char);
}
%define api.prefix "gram_"
-%define api.pure
+%define api.pure full
%define locations
%define parse.error verbose
%define parse.lac full
--
1.8.1.2
- [PATCH 0/5] {master} cleaning up, Akim Demaille, 2013/02/04
- [PATCH 3/5] style: space changes in the parser, Akim Demaille, 2013/02/04
- [PATCH 5/5] tests: improve the language independance layer, Akim Demaille, 2013/02/04
- [PATCH 2/5] parser: use api.pure full,
Akim Demaille <=
- [PATCH 4/5] regen, Akim Demaille, 2013/02/04
- [PATCH 1/5] style: use a for loop instead of a while loop, and scope reduction, Akim Demaille, 2013/02/04