(YYOPTIONAL_LOC): Define even if it's not a recent

version of GCC, since the macro is used with non-GCC compilers.
This commit is contained in:
Paul Eggert
2005-07-25 04:20:39 +00:00
parent e0045d49b6
commit 3bc00d6c4b

View File

@@ -261,18 +261,18 @@ b4_syncline([@oline@], [@ofile@])
#ifndef __attribute__ #ifndef __attribute__
/* This feature is available in gcc versions 2.5 and later. */ /* This feature is available in gcc versions 2.5 and later. */
# if !defined (__GNUC__) || __GNUC__ < 2 || \ # if (!defined (__GNUC__) || __GNUC__ < 2 \
(__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__ || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__)
# define __attribute__(Spec) /* empty */ # define __attribute__(Spec) /* empty */
# else # endif
#endif
]b4_location_if([#define YYOPTIONAL_LOC(Name) Name],[ ]b4_location_if([#define YYOPTIONAL_LOC(Name) Name],[
# if defined (__cplusplus) #ifdef __cplusplus
# define YYOPTIONAL_LOC(Name) /* empty */ # define YYOPTIONAL_LOC(Name) /* empty */
#else #else
# define YYOPTIONAL_LOC(Name) Name __attribute__ ((__unused__)) # define YYOPTIONAL_LOC(Name) Name __attribute__ ((__unused__))
#endif])[ #endif])[
# endif
#endif
#ifndef YYASSERT #ifndef YYASSERT
# define YYASSERT(condition) ((void) ((condition) || (abort (), 0))) # define YYASSERT(condition) ((void) ((condition) || (abort (), 0)))