#include <glib.h>
#include "parse.h"
+#include "main.h"
+
+extern gboolean for_cpp;
static int parenth_depth = 0;
static int before_comment = INITIAL;
return CLASS;
}
+<CLASS_CODE,CLASS_CODE_I>class|this {
+ if(for_cpp) {
+ char *s;
+ s = g_strdup_printf("'%s' keyword should not "
+ "be used when generating "
+ "C++ code",yytext);
+ print_error(TRUE,s, line_no);
+ g_free(s);
+ }
+ REJECT;
+ }
+
<CLASS_CODE>from {return FROM;}
<CLASS_CODE_I>void {return VOID;}