mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
* data/yacc.c [(! defined yyoverflow || YYERROR_VERBOSE) && !
YYSTACK_USE_ALLOCA && ! defined YYSTACK_ALLOC && defined __cplusplus && ! defined _STDLIB_H && ! ((defined YYMALLOC || defined malloc) && (defined YYFREE || defined free))]: Include <stdlib.h> rather than rolling our own declarations of malloc and free, to avoid problems with incompatible declarations (using 'throw') C++'s stdlib.h. This should fix Debian bug 340012 <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=340012>, reported by Guillaume Melquiond.
This commit is contained in:
13
ChangeLog
13
ChangeLog
@@ -1,3 +1,16 @@
|
|||||||
|
2006-02-16 Paul Eggert <eggert@cs.ucla.edu>
|
||||||
|
|
||||||
|
* data/yacc.c [(! defined yyoverflow || YYERROR_VERBOSE) && !
|
||||||
|
YYSTACK_USE_ALLOCA && ! defined YYSTACK_ALLOC && defined
|
||||||
|
__cplusplus && ! defined _STDLIB_H && !
|
||||||
|
((defined YYMALLOC || defined malloc) && (defined YYFREE ||
|
||||||
|
defined free))]: Include <stdlib.h> rather than rolling our own
|
||||||
|
declarations of malloc and free, to avoid problems with
|
||||||
|
incompatible declarations (using 'throw') C++'s stdlib.h. This
|
||||||
|
should fix Debian bug 340012
|
||||||
|
<http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=340012>,
|
||||||
|
reported by Guillaume Melquiond.
|
||||||
|
|
||||||
2006-02-13 Paul Eggert <eggert@cs.ucla.edu>
|
2006-02-13 Paul Eggert <eggert@cs.ucla.edu>
|
||||||
|
|
||||||
* NEWS: Clarify symbols versus types in unused-value warnings.
|
* NEWS: Clarify symbols versus types in unused-value warnings.
|
||||||
|
|||||||
12
data/yacc.c
12
data/yacc.c
@@ -338,8 +338,13 @@ typedef short int yytype_int16;
|
|||||||
# ifndef YYSTACK_ALLOC_MAXIMUM
|
# ifndef YYSTACK_ALLOC_MAXIMUM
|
||||||
# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
|
# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
|
||||||
# endif
|
# endif
|
||||||
# ifdef __cplusplus
|
# if (defined __cplusplus && ! defined _STDLIB_H \
|
||||||
extern "C" {
|
&& ! ((defined YYMALLOC || defined malloc) \
|
||||||
|
&& (defined YYFREE || defined free)))
|
||||||
|
# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
|
||||||
|
# ifndef _STDLIB_H
|
||||||
|
# define _STDLIB_H 1
|
||||||
|
# endif
|
||||||
# endif
|
# endif
|
||||||
# ifndef YYMALLOC
|
# ifndef YYMALLOC
|
||||||
# define YYMALLOC malloc
|
# define YYMALLOC malloc
|
||||||
@@ -353,9 +358,6 @@ void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
|
|||||||
void free (void *); /* INFRINGES ON USER NAME SPACE */
|
void free (void *); /* INFRINGES ON USER NAME SPACE */
|
||||||
# endif
|
# endif
|
||||||
# endif
|
# endif
|
||||||
# ifdef __cplusplus
|
|
||||||
}
|
|
||||||
# endif
|
|
||||||
# endif
|
# endif
|
||||||
#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
|
#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user