[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 4/8] tests: portability fixes.
From: |
Akim Demaille |
Subject: |
[PATCH 4/8] tests: portability fixes. |
Date: |
Wed, 4 Jul 2012 16:53:00 +0200 |
Reported by Hydra.
* tests/headers.at (Several headers): Be sure to include config.h
in the files to compile.
---
tests/headers.at | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/tests/headers.at b/tests/headers.at
index 4660f97..2eba776 100644
--- a/tests/headers.at
+++ b/tests/headers.at
@@ -130,7 +130,7 @@ AT_SETUP([Several parsers])
# the header (but YYDEBUG and YYPARSE_PARAM).
m4_define([AT_DATA_GRAMMAR_SEVERAL],
[AT_BISON_OPTION_PUSHDEFS([%define api.prefix "$1_" $2])
-AT_DATA_GRAMMAR([AT_SKEL_CC_IF([$1.yy], [$1.y])],
+AT_DATA_GRAMMAR([$1.AT_SKEL_CC_IF([yy], [y])],
[[%define api.prefix "$1_"
$2
%union
@@ -166,8 +166,8 @@ AT_BISON_OPTION_POPDEFS
])
AT_DATA([main.cc],
-[[#define ECHO(S) std::cerr << #S": " << S << std::endl;
-extern "C"
+[AT_DATA_SOURCE_PROLOGUE
+[extern "C"
{
#include "x1.h"
#include "x2.h"
@@ -177,6 +177,8 @@ extern "C"
#include "x5.hh"
//#include "x6.hh"
+#define ECHO(S) std::cerr << #S": " << S << std::endl;
+
int
main (void)
{
--
1.7.11.1
- [PATCH 0/8] Various improvements prompted by api.prefix, Akim Demaille, 2012/07/04
- [PATCH 3/8] c++: fewer #includes in the headers., Akim Demaille, 2012/07/04
- [PATCH 5/8] api.prefix: do not use #define to handle YYSTYPE_IS_TRIVIAL etc., Akim Demaille, 2012/07/04
- [PATCH 7/8] glr.cc: do not override C++ definitions by C macros., Akim Demaille, 2012/07/04
- [PATCH 1/8] tests: more logs., Akim Demaille, 2012/07/04
- [PATCH 6/8] YYLLOC_DEFAULT: factor, and don't export it in headers., Akim Demaille, 2012/07/04
- [PATCH 2/8] glr.cc: formatting changes., Akim Demaille, 2012/07/04
- [PATCH 4/8] tests: portability fixes.,
Akim Demaille <=
- [PATCH 8/8] tests: headers.at: strengthen., Akim Demaille, 2012/07/04