1%{ 2/* Keyword definition for the GNU compiler for the Java(TM) language. 3 Copyright (C) 1997, 1998 Free Software Foundation, Inc. 4 Contributed by Alexandre Petit-Bianco (apbianco@cygnus.com) 5 6This file is part of GNU CC. 7 8GNU CC is free software; you can redistribute it and/or modify 9it under the terms of the GNU General Public License as published by 10the Free Software Foundation; either version 2, or (at your option) 11any later version. 12 13GNU CC is distributed in the hope that it will be useful, 14but WITHOUT ANY WARRANTY; without even the implied warranty of 15MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16GNU General Public License for more details. 17 18You should have received a copy of the GNU General Public License 19along with GNU CC; see the file COPYING. If not, write to 20the Free Software Foundation, 59 Temple Place - Suite 330, 21Boston, MA 02111-1307, USA. 22 23Java and all Java-based marks are trademarks or registered trademarks 24of Sun Microsystems, Inc. in the United States and other countries. 25The Free Software Foundation is independent of Sun Microsystems, Inc. */ 26 27%} 28struct java_keyword { const char *const name; const int token; }; 29#ifdef __GNUC__ 30__inline 31#endif 32static unsigned int hash PARAMS ((const char *, unsigned int)); 33#ifdef __GNUC__ 34__inline 35#endif 36const struct java_keyword *java_keyword PARAMS ((const char *, unsigned int)); 37%% 38abstract, ABSTRACT_TK 39default, DEFAULT_TK 40if, IF_TK 41private, PRIVATE_TK 42throw, THROW_TK 43boolean, BOOLEAN_TK 44do, DO_TK 45implements, IMPLEMENTS_TK 46protected, PROTECTED_TK 47throws, THROWS_TK 48break, BREAK_TK 49double, DOUBLE_TK 50import, IMPORT_TK 51public, PUBLIC_TK 52transient, TRANSIENT_TK 53byte, BYTE_TK 54else, ELSE_TK 55instanceof, INSTANCEOF_TK 56return, RETURN_TK 57try, TRY_TK 58case, CASE_TK 59extends, EXTENDS_TK 60int, INT_TK 61short, SHORT_TK 62void, VOID_TK 63catch, CATCH_TK 64final, FINAL_TK 65interface, INTERFACE_TK 66static, STATIC_TK 67volatile, VOLATILE_TK 68char, CHAR_TK 69finally, FINALLY_TK 70long, LONG_TK 71super, SUPER_TK 72while, WHILE_TK 73class, CLASS_TK 74float, FLOAT_TK 75native, NATIVE_TK 76switch, SWITCH_TK 77const, CONST_TK 78for, FOR_TK 79new, NEW_TK 80synchronized, SYNCHRONIZED_TK 81continue, CONTINUE_TK 82goto, GOTO_TK 83package, PACKAGE_TK 84this, THIS_TK 85strictfp, STRICT_TK 86# true, false and null aren't keyword. But we match them easily this way 87true, TRUE_TK 88false, FALSE_TK 89null, NULL_TK 90assert, ASSERT_TK 91