Skip to content
Snippets Groups Projects
Commit 4bd3fef6 authored by Graham Madarasz's avatar Graham Madarasz
Browse files

MAINT-2612 fix issues between extern C linkage and yyval ifdefs on Mac with toolchain > 4.5.1

parent b7235f1a
No related branches found
No related tags found
No related merge requests found
...@@ -79,11 +79,17 @@ void parse_string(); ...@@ -79,11 +79,17 @@ void parse_string();
#define yyfree indra_free #define yyfree indra_free
#if LL_DARWIN
int yyparse( void );
int yylex( void );
int yyerror(const char *fmt, ...);
#else
#if defined(__cplusplus) #if defined(__cplusplus)
extern "C" { int yylex( void ); }
extern "C" { int yyparse( void ); } extern "C" { int yyparse( void ); }
extern "C" { int yylex( void ); }
extern "C" { int yyerror(const char *fmt, ...); } extern "C" { int yyerror(const char *fmt, ...); }
#endif #endif
#endif
%} %}
......
...@@ -2,8 +2,10 @@ ...@@ -2,8 +2,10 @@
#include "linden_common.h" #include "linden_common.h"
#include "lscript_tree.h" #include "lscript_tree.h"
#ifdef __cplusplus #if !LL_DARWIN
#ifdef __cplusplus
extern "C" { extern "C" {
#endif
#endif #endif
int yylex(void); int yylex(void);
...@@ -20,9 +22,11 @@ ...@@ -20,9 +22,11 @@
#pragma warning( disable : 4065 ) // warning: switch statement contains 'default' but no 'case' labels #pragma warning( disable : 4065 ) // warning: switch statement contains 'default' but no 'case' labels
#endif #endif
#if !LL_DARWIN
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif
#endif
%} %}
%union %union
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment