diff options
author | Jeff Cohen <jeffc@jolt-lang.org> | 2007-01-21 19:30:52 +0000 |
---|---|---|
committer | Jeff Cohen <jeffc@jolt-lang.org> | 2007-01-21 19:30:52 +0000 |
commit | ac2dca9a6f59a2e7fdc4de48c456860b6ecd19a9 (patch) | |
tree | 979c9534fcf33a7df949e74fa24cfd954d8d8e62 | |
parent | 361c3efd9aec432f2ede5e49ab02f2549c485aa8 (diff) |
Fix a bunch of missing semicolon parse errors from bison.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33426 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | tools/llvm-upgrade/UpgradeParser.cpp.cvs | 2841 | ||||
-rw-r--r-- | tools/llvm-upgrade/UpgradeParser.h.cvs | 29 | ||||
-rw-r--r-- | tools/llvm-upgrade/UpgradeParser.y | 8 | ||||
-rw-r--r-- | tools/llvm-upgrade/UpgradeParser.y.cvs | 8 |
4 files changed, 1334 insertions, 1552 deletions
diff --git a/tools/llvm-upgrade/UpgradeParser.cpp.cvs b/tools/llvm-upgrade/UpgradeParser.cpp.cvs index 5b57b5d8a2..b65ac101d2 100644 --- a/tools/llvm-upgrade/UpgradeParser.cpp.cvs +++ b/tools/llvm-upgrade/UpgradeParser.cpp.cvs @@ -1,7 +1,7 @@ -/* A Bison parser, made by GNU Bison 2.1. */ +/* A Bison parser, made from /usr/home/jeffc/llvm/tools/llvm-upgrade/UpgradeParser.y, by GNU bison 1.75. */ /* Skeleton parser for Yacc-like parsing with Bison, - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -15,8 +15,8 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, - Boston, MA 02110-1301, USA. */ + Foundation, Inc., 59 Temple Place - Suite 330, + Boston, MA 02111-1307, USA. */ /* As a special exception, when this file is copied by Bison into a Bison output file, you may use that output file without restriction. @@ -34,21 +34,16 @@ USER NAME SPACE" below. */ /* Identify Bison output. */ -#define YYBISON 1 - -/* Bison version. */ -#define YYBISON_VERSION "2.1" - -/* Skeleton name. */ -#define YYSKELETON_NAME "yacc.c" +#define YYBISON 1 /* Pure parsers. */ -#define YYPURE 0 +#define YYPURE 0 /* Using locations. */ #define YYLSP_NEEDED 0 -/* Substitute the variable and function names. */ +/* If NAME_PREFIX is specified substitute the variables and functions + names. */ #define yyparse Upgradeparse #define yylex Upgradelex #define yyerror Upgradeerror @@ -213,7 +208,6 @@ BITCAST = 404 }; #endif -/* Tokens. */ #define VOID 258 #define BOOL 259 #define SBYTE 260 @@ -366,7 +360,7 @@ /* Copy the first part of user declarations. */ -#line 14 "/proj/llvm/llvm-2/tools/llvm-upgrade/UpgradeParser.y" +#line 14 "/usr/home/jeffc/llvm/tools/llvm-upgrade/UpgradeParser.y" #include "UpgradeInternals.h" #include <algorithm> @@ -1335,75 +1329,53 @@ const Type* getType(const std::string& newTy, TypeIDs oldTy) { # define YYERROR_VERBOSE 0 #endif -/* Enabling the token table. */ -#ifndef YYTOKEN_TABLE -# define YYTOKEN_TABLE 0 -#endif - -#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED) -#line 971 "/proj/llvm/llvm-2/tools/llvm-upgrade/UpgradeParser.y" -typedef union YYSTYPE { +#ifndef YYSTYPE +#line 971 "/usr/home/jeffc/llvm/tools/llvm-upgrade/UpgradeParser.y" +typedef union { std::string* String; const Type* Ty; Value* Val; Constant* Const; ValueList* ValList; TypeList* TypeVec; -} YYSTYPE; -/* Line 196 of yacc.c. */ -#line 1355 "UpgradeParser.tab.c" -# define yystype YYSTYPE /* obsolescent; will be withdrawn */ -# define YYSTYPE_IS_DECLARED 1 +} yystype; +/* Line 188 of /usr/local/share/bison/yacc.c. */ +#line 1344 "UpgradeParser.tab.c" +# define YYSTYPE yystype # define YYSTYPE_IS_TRIVIAL 1 #endif - +#ifndef YYLTYPE +typedef struct yyltype +{ + int first_line; + int first_column; + int last_line; + int last_column; +} yyltype; +# define YYLTYPE yyltype +# define YYLTYPE_IS_TRIVIAL 1 +#endif /* Copy the second part of user declarations. */ -/* Line 219 of yacc.c. */ -#line 1367 "UpgradeParser.tab.c" - -#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__) -# define YYSIZE_T __SIZE_TYPE__ -#endif -#if ! defined (YYSIZE_T) && defined (size_t) -# define YYSIZE_T size_t -#endif -#if ! defined (YYSIZE_T) && (defined (__STDC__) || defined (__cplusplus)) -# include <stddef.h> /* INFRINGES ON USER NAME SPACE */ -# define YYSIZE_T size_t -#endif -#if ! defined (YYSIZE_T) -# define YYSIZE_T unsigned int -#endif - -#ifndef YY_ -# if YYENABLE_NLS -# if ENABLE_NLS -# include <libintl.h> /* INFRINGES ON USER NAME SPACE */ -# define YY_(msgid) dgettext ("bison-runtime", msgid) -# endif -# endif -# ifndef YY_ -# define YY_(msgid) msgid -# endif -#endif +/* Line 213 of /usr/local/share/bison/yacc.c. */ +#line 1365 "UpgradeParser.tab.c" #if ! defined (yyoverflow) || YYERROR_VERBOSE /* The parser invokes alloca or malloc; define the necessary symbols. */ -# ifdef YYSTACK_USE_ALLOCA -# if YYSTACK_USE_ALLOCA -# ifdef __GNUC__ -# define YYSTACK_ALLOC __builtin_alloca -# else +# if YYSTACK_USE_ALLOCA +# define YYSTACK_ALLOC alloca +# else +# ifndef YYSTACK_USE_ALLOCA +# if defined (alloca) || defined (_ALLOCA_H) # define YYSTACK_ALLOC alloca -# if defined (__STDC__) || defined (__cplusplus) -# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ -# define YYINCLUDED_STDLIB_H +# else +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca # endif # endif # endif @@ -1412,76 +1384,50 @@ typedef union YYSTYPE { # ifdef YYSTACK_ALLOC /* Pacify GCC's `empty if-body' warning. */ # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) -# ifndef YYSTACK_ALLOC_MAXIMUM - /* The OS might guarantee only one guard page at the bottom of the stack, - and a page size can be as small as 4096 bytes. So we cannot safely - invoke alloca (N) if N exceeds 4096. Use a slightly smaller number - to allow for a few compiler-allocated temporary stack slots. */ -# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2005 */ -# endif # else -# define YYSTACK_ALLOC YYMALLOC -# define YYSTACK_FREE YYFREE -# ifndef YYSTACK_ALLOC_MAXIMUM -# define YYSTACK_ALLOC_MAXIMUM ((YYSIZE_T) -1) -# endif -# ifdef __cplusplus -extern "C" { -# endif -# ifndef YYMALLOC -# define YYMALLOC malloc -# if (! defined (malloc) && ! defined (YYINCLUDED_STDLIB_H) \ - && (defined (__STDC__) || defined (__cplusplus))) -void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ -# endif -# endif -# ifndef YYFREE -# define YYFREE free -# if (! defined (free) && ! defined (YYINCLUDED_STDLIB_H) \ - && (defined (__STDC__) || defined (__cplusplus))) -void free (void *); /* INFRINGES ON USER NAME SPACE */ -# endif -# endif -# ifdef __cplusplus -} +# if defined (__STDC__) || defined (__cplusplus) +# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t # endif +# define YYSTACK_ALLOC malloc +# define YYSTACK_FREE free # endif #endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */ #if (! defined (yyoverflow) \ && (! defined (__cplusplus) \ - || (defined (YYSTYPE_IS_TRIVIAL) && YYSTYPE_IS_TRIVIAL))) + || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) /* A type that is properly aligned for any stack member. */ union yyalloc { - short int yyss; + short yyss; YYSTYPE yyvs; }; /* The size of the maximum gap between one aligned stack and the next. */ -# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) +# define YYSTACK_GAP_MAX (sizeof (union yyalloc) - 1) /* The size of an array large to enough to hold all stacks, each with N elements. */ # define YYSTACK_BYTES(N) \ - ((N) * (sizeof (short int) + sizeof (YYSTYPE)) \ - + YYSTACK_GAP_MAXIMUM) + ((N) * (sizeof (short) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAX) /* Copy COUNT objects from FROM to TO. The source and destination do not overlap. */ # ifndef YYCOPY -# if defined (__GNUC__) && 1 < __GNUC__ +# if 1 < __GNUC__ # define YYCOPY(To, From, Count) \ __builtin_memcpy (To, From, (Count) * sizeof (*(From))) # else # define YYCOPY(To, From, Count) \ do \ { \ - YYSIZE_T yyi; \ + register YYSIZE_T yyi; \ for (yyi = 0; yyi < (Count); yyi++) \ - (To)[yyi] = (From)[yyi]; \ + (To)[yyi] = (From)[yyi]; \ } \ while (0) # endif @@ -1498,7 +1444,7 @@ union yyalloc YYSIZE_T yynewbytes; \ YYCOPY (&yyptr->Stack, Stack, yysize); \ Stack = &yyptr->Stack; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX; \ yyptr += yynewbytes / sizeof (*yyptr); \ } \ while (0) @@ -1508,12 +1454,11 @@ union yyalloc #if defined (__STDC__) || defined (__cplusplus) typedef signed char yysigned_char; #else - typedef short int yysigned_char; + typedef short yysigned_char; #endif /* YYFINAL -- State number of the termination state. */ #define YYFINAL 4 -/* YYLAST -- Last index in YYTABLE. */ #define YYLAST 1473 /* YYNTOKENS -- Number of terminals. */ @@ -1529,8 +1474,8 @@ union yyalloc #define YYUNDEFTOK 2 #define YYMAXUTOK 404 -#define YYTRANSLATE(YYX) \ - ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) +#define YYTRANSLATE(X) \ + ((unsigned)(X) <= YYMAXUTOK ? yytranslate[X] : YYUNDEFTOK) /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ static const unsigned char yytranslate[] = @@ -1581,7 +1526,7 @@ static const unsigned char yytranslate[] = #if YYDEBUG /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in YYRHS. */ -static const unsigned short int yyprhs[] = +static const unsigned short yyprhs[] = { 0, 0, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, @@ -1617,7 +1562,7 @@ static const unsigned short int yyprhs[] = }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ -static const short int yyrhs[] = +static const short yyrhs[] = { 198, 0, -1, 19, -1, 20, -1, 17, -1, 18, -1, 79, -1, 80, -1, 81, -1, 82, -1, 83, @@ -1716,7 +1661,7 @@ static const short int yyrhs[] = }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ -static const unsigned short int yyrline[] = +static const unsigned short yyrline[] = { 0, 1036, 1036, 1036, 1037, 1037, 1041, 1041, 1041, 1041, 1041, 1041, 1041, 1042, 1042, 1042, 1042, 1043, 1043, 1043, @@ -1724,7 +1669,7 @@ static const unsigned short int yyrline[] = 1045, 1045, 1045, 1045, 1045, 1045, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1047, 1047, 1047, 1047, 1047, 1047, 1048, 1048, 1048, 1048, 1049, 1049, 1049, 1049, - 1049, 1049, 1049, 1050, 1050, 1050, 1050, 1050, 1050, 1055, + 1049, 1049, 1049, 1049, 1050, 1050, 1050, 1050, 1050, 1055, 1055, 1055, 1055, 1056, 1056, 1056, 1056, 1057, 1057, 1058, 1058, 1061, 1064, 1069, 1069, 1069, 1069, 1069, 1069, 1070, 1071, 1074, 1074, 1074, 1074, 1074, 1075, 1076, 1081, 1086, @@ -1736,73 +1681,74 @@ static const unsigned short int yyrline[] = 1280, 1286, 1293, 1300, 1308, 1315, 1322, 1329, 1336, 1343, 1350, 1358, 1372, 1384, 1389, 1395, 1400, 1406, 1411, 1416, 1424, 1429, 1434, 1444, 1449, 1454, 1454, 1464, 1469, 1472, - 1477, 1481, 1485, 1487, 1487, 1490, 1500, 1505, 1510, 1520, - 1530, 1540, 1550, 1555, 1560, 1565, 1567, 1567, 1570, 1575, - 1582, 1587, 1594, 1601, 1606, 1607, 1615, 1615, 1616, 1616, - 1618, 1627, 1631, 1635, 1638, 1643, 1646, 1649, 1672, 1673, - 1676, 1687, 1688, 1690, 1699, 1700, 1701, 1705, 1705, 1719, - 1720, 1723, 1723, 1723, 1723, 1723, 1723, 1723, 1724, 1725, - 1730, 1731, 1740, 1740, 1744, 1750, 1761, 1770, 1773, 1781, - 1785, 1790, 1793, 1799, 1799, 1801, 1806, 1811, 1816, 1824, - 1834, 1843, 1865, 1870, 1876, 1882, 1890, 1908, 1917, 1927, - 1931, 1938, 1939, 1943, 1948, 1951, 1962, 1972, 1983, 1993, - 2003, 2014, 2044, 2053, 2060, 2069, 2076, 2083, 2089, 2140, - 2145, 2146, 2150, 2151, 2154, 2163, 2173, 2182, 2193, 2200, - 2211, 2222 + 1477, 1481, 1485, 1488, 1488, 1491, 1501, 1506, 1511, 1521, + 1531, 1541, 1551, 1556, 1561, 1566, 1568, 1568, 1571, 1576, + 1583, 1588, 1595, 1602, 1607, 1608, 1616, 1616, 1617, 1617, + 1619, 1628, 1632, 1636, 1639, 1644, 1647, 1650, 1673, 1674, + 1678, 1689, 1690, 1692, 1701, 1702, 1703, 1707, 1707, 1721, + 1722, 1725, 1725, 1725, 1725, 1725, 1725, 1725, 1726, 1727, + 1732, 1733, 1742, 1742, 1746, 1752, 1763, 1772, 1775, 1783, + 1787, 1792, 1795, 1801, 1801, 1803, 1808, 1813, 1818, 1826, + 1836, 1845, 1867, 1872, 1878, 1884, 1892, 1910, 1919, 1929, + 1933, 1940, 1941, 1945, 1950, 1953, 1964, 1974, 1985, 1995, + 2005, 2016, 2046, 2055, 2062, 2071, 2078, 2085, 2091, 2142, + 2147, 2148, 2152, 2153, 2156, 2165, 2175, 2184, 2195, 2202, + 2213, 2224 }; #endif -#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE -/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. +#if YYDEBUG || YYERROR_VERBOSE +/* YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. First, the terminals, then, starting at YYNTOKENS, nonterminals. */ static const char *const yytname[] = { - "$end", "error", "$undefined", "VOID", "BOOL", "SBYTE", "UBYTE", - "SHORT", "USHORT", "INT", "UINT", "LONG", "ULONG", "FLOAT", "DOUBLE", - "LABEL", "OPAQUE", "ESINT64VAL", "EUINT64VAL", "SINTVAL", "UINTVAL", - "FPVAL", "NULL_TOK", "UNDEF", "ZEROINITIALIZER", "TRUETOK", "FALSETOK", - "TYPE", "VAR_ID", "LABELSTR", "STRINGCONSTANT", "IMPLEMENTATION", - "BEGINTOK", "ENDTOK", "DECLARE", "GLOBAL", "CONSTANT", "SECTION", - "VOLATILE", "TO", "DOTDOTDOT", "CONST", "INTERNAL", "LINKONCE", "WEAK", - "DLLIMPORT", "DLLEXPORT", "EXTERN_WEAK", "APPENDING", "EXTERNAL", - "TARGET", "TRIPLE", "ENDIAN", "POINTERSIZE", "LITTLE", "BIG", "ALIGN", - "UNINITIALIZED", "DEPLIBS", "CALL", "TAIL", "ASM_TOK", "MODULE", - "SIDEEFFECT", "CC_TOK", "CCC_TOK", "CSRETCC_TOK", "FASTCC_TOK", - "COLDCC_TOK", "X86_STDCALLCC_TOK", "X86_FASTCALLCC_TOK", "DATALAYOUT", - "RET", "BR", "SWITCH", "INVOKE", "EXCEPT", "UNWIND", "UNREACHABLE", - "ADD", "SUB", "MUL", "DIV", "UDIV", "SDIV", "FDIV", "REM", "UREM", - "SREM", "FREM", "AND", "OR", "XOR", "SETLE", "SETGE", "SETLT", "SETGT", - "SETEQ", "SETNE", "ICMP", "FCMP", "EQ", "NE", "SLT", "SGT", "SLE", "SGE", - "OEQ", "ONE", "OLT", "OGT", "OLE", "OGE", "ORD", "UNO", "UEQ", "UNE", - "ULT", "UGT", "ULE", "UGE", "MALLOC", "ALLOCA", "FREE", "LOAD", "STORE", - "GETELEMENTPTR", "PHI_TOK", "SELECT", "SHL", "SHR", "ASHR", "LSHR", - "VAARG", "EXTRACTELEMENT", "INSERTELEMENT", "SHUFFLEVECTOR", "CAST", - "TRUNC", "ZEXT", "SEXT", "FPTRUNC", "FPEXT", "FPTOUI", "FPTOSI", - "UITOFP", "SITOFP", "PTRTOINT", "INTTOPTR", "BITCAST", "'='", "','", - "'\\\\'", "'('", "')'", "'['", "'x'", "']'", "'<'", "'>'", "'{'", "'}'", - "'*'", "'c'", "$accept", "IntVal", "EInt64Val", "ArithmeticOps", - "LogicalOps", "SetCondOps", "IPredicates", "FPredicates", "ShiftOps", - "CastOps", "SIntType", "UIntType", "IntType", "FPType", "OptAssign", - "OptLinkage", "OptCallingConv", "OptAlign", "OptCAlign", "SectionString", - "OptSection", "GlobalVarAttributes", "GlobalVarAttribute", "TypesV", - "UpRTypesV", "Types", "PrimType", "UpRTypes", "TypeListI", - "ArgTypeListI", "ConstVal", "ConstExpr", "ConstVector", "GlobalType", - "Module", "DefinitionList", "External", "ConstPool", "AsmBlock", - "BigOrLittle", "TargetDefinition", "LibrariesDefinition", "LibList", - "Name", "OptName", "ArgVal", "ArgListH", "ArgList", "FunctionHeaderH", - "BEGIN", "FunctionHeader", "END", "Function", "FnDeclareLinkage", - "FunctionProto", "@1", "OptSideEffect", "ConstValueRef", - "SymbolicValueRef", "ValueRef", "ResolvedVal", "BasicBlockList", - "BasicBlock", "InstructionList", "Unwind", "BBTerminatorInst", - "JumpTable", "Inst", "PHIList", "ValueRefList", "ValueRefListE", - "OptTailCall", "InstVal", "IndexList", "OptVolatile", "MemoryInst", 0 + "$end", "error", "$undefined", "VOID", "BOOL", "SBYTE", "UBYTE", "SHORT", + "USHORT", "INT", "UINT", "LONG", "ULONG", "FLOAT", "DOUBLE", "LABEL", + "OPAQUE", "ESINT64VAL", "EUINT64VAL", "SINTVAL", "UINTVAL", "FPVAL", + "NULL_TOK", "UNDEF", "ZEROINITIALIZER", "TRUETOK", "FALSETOK", "TYPE", + "VAR_ID", "LABELSTR", "STRINGCONSTANT", "IMPLEMENTATION", "BEGINTOK", + "ENDTOK", "DECLARE", "GLOBAL", "CONSTANT", "SECTION", "VOLATILE", "TO", + "DOTDOTDOT", "CONST", "INTERNAL", "LINKONCE", "WEAK", "DLLIMPORT", + "DLLEXPORT", "EXTERN_WEAK", "APPENDING", "EXTERNAL", "TARGET", "TRIPLE", + "ENDIAN", "POINTERSIZE", "LITTLE", "BIG", "ALIGN", "UNINITIALIZED", + "DEPLIBS", "CALL", "TAIL", "ASM_TOK", "MODULE", "SIDEEFFECT", "CC_TOK", + "CCC_TOK", "CSRETCC_TOK", "FASTCC_TOK", "COLDCC_TOK", + "X86_STDCALLCC_TOK", "X86_FASTCALLCC_TOK", "DATALAYOUT", "RET", "BR", + "SWITCH", "INVOKE", "EXCEPT", "UNWIND", "UNREACHABLE", "ADD", "SUB", + "MUL", "DIV", "UDIV", "SDIV", "FDIV", "REM", "UREM", "SREM", "FREM", + "AND", "OR", "XOR", "SETLE", "SETGE", "SETLT", "SETGT", "SETEQ", + "SETNE", "ICMP", "FCMP", "EQ", "NE", "SLT", "SGT", "SLE", "SGE", "OEQ", + "ONE", "OLT", "OGT", "OLE", "OGE", "ORD", "UNO", "UEQ", "UNE", "ULT", + "UGT", "ULE", "UGE", "MALLOC", "ALLOCA", "FREE", "LOAD", "STORE", + "GETELEMENTPTR", "PHI_TOK", "SELECT", "SHL", "SHR", "ASHR", "LSHR", + "VAARG", "EXTRACTELEMENT", "INSERTELEMENT", "SHUFFLEVECTOR", "CAST", + "TRUNC", "ZEXT", "SEXT", "FPTRUNC", "FPEXT", "FPTOUI", "FPTOSI", + "UITOFP", "SITOFP", "PTRTOINT", "INTTOPTR", "BITCAST", "'='", "','", + "'\\\\'", "'('", "')'", "'['", "'x'", "']'", "'<'", "'>'", "'{'", "'}'", + "'*'", "'c'", "$accept", "IntVal", "EInt64Val", "ArithmeticOps", + "LogicalOps", "SetCondOps", "IPredicates", "FPredicates", "ShiftOps", + "CastOps", "SIntType", "UIntType", "IntType", "FPType", "OptAssign", + "OptLinkage", "OptCallingConv", "OptAlign", "OptCAlign", + "SectionString", "OptSection", "GlobalVarAttributes", + "GlobalVarAttribute", "TypesV", "UpRTypesV", "Types", "PrimType", + "UpRTypes", "TypeListI", "ArgTypeListI", "ConstVal", "ConstExpr", + "ConstVector", "GlobalType", "Module", "DefinitionList", "External", + "ConstPool", "AsmBlock", "BigOrLittle", "TargetDefinition", + "LibrariesDefinition", "LibList", "Name", "OptName", "ArgVal", + "ArgListH", "ArgList", "FunctionHeaderH", "BEGIN", "FunctionHeader", + "END", "Function", "FnDeclareLinkage", "FunctionProto", "@1", + "OptSideEffect", "ConstValueRef", "SymbolicValueRef", "ValueRef", + "ResolvedVal", "BasicBlockList", "BasicBlock", "InstructionList", + "Unwind", "BBTerminatorInst", "JumpTable", "Inst", "PHIList", + "ValueRefList", "ValueRefListE", "OptTailCall", "InstVal", "IndexList", + "OptVolatile", "MemoryInst", 0 }; #endif # ifdef YYPRINT /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to token YYLEX-NUM. */ -static const unsigned short int yytoknum[] = +static const unsigned short yytoknum[] = { 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, @@ -1899,7 +1845,7 @@ static const unsigned char yyr2[] = /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state STATE-NUM when YYTABLE doesn't specify something else to do. Zero means the default is an error. */ -static const unsigned short int yydefact[] = +static const unsigned short yydefact[] = { 194, 0, 90, 182, 1, 181, 227, 83, 84, 85, 87, 88, 89, 86, 0, 98, 251, 178, 179, 206, @@ -1963,7 +1909,7 @@ static const unsigned short int yydefact[] = }; /* YYDEFGOTO[NTERM-NUM]. */ -static const short int yydefgoto[] = +static const short yydefgoto[] = { -1, 83, 336, 266, 267, 268, 290, 307, 269, 270, 233, 234, 149, 235, 24, 15, 36, 507, 384, 406, @@ -1978,7 +1924,7 @@ static const short int yydefgoto[] = /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ #define YYPACT_NINF -537 -static const short int yypact[] = +static const short yypact[] = { -537, 75, 61, 1145, -537, -537, -537, -537, -537, -537, -537, -537, -537, -537, 18, 180, 55, -537, -537, -537, @@ -2042,7 +1988,7 @@ static const short int yypact[] = }; /* YYPGOTO[NTERM-NUM]. */ -static const short int yypgoto[] = +static const short yypgoto[] = { -537, -537, 226, 361, 362, 365, 209, 214, 368, 370, -99, -98, -507, -537, 420, 452, -134, -537, -303, 57, @@ -2057,9 +2003,9 @@ static const short int yypgoto[] = /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which number is the opposite. If zero, do what YYDEFACT says. - If YYTABLE_NINF, syntax error. */ + If YYTABLE_NINF, parse error. */ #define YYTABLE_NINF -178 -static const short int yytable[] = +static const short yytable[] = { 86, 147, 148, 129, 115, 331, 386, 25, 91, 237, 136, 442, 125, 86, 38, 552, 565, 444, 94, 279, @@ -2211,7 +2157,7 @@ static const short int yytable[] = 199, 200, 201, 202 }; -static const short int yycheck[] = +static const short yycheck[] = { 36, 100, 100, 82, 49, 221, 309, 3, 32, 120, 98, 10, 18, 49, 29, 522, 552, 10, 33, 153, @@ -2428,15 +2374,30 @@ static const unsigned char yystos[] = 15, 228, 223, 15, 223 }; +#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__) +# define YYSIZE_T __SIZE_TYPE__ +#endif +#if ! defined (YYSIZE_T) && defined (size_t) +# define YYSIZE_T size_t +#endif +#if ! defined (YYSIZE_T) +# if defined (__STDC__) || defined (__cplusplus) +# include <stddef.h> /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# endif +#endif +#if ! defined (YYSIZE_T) +# define YYSIZE_T unsigned int +#endif + #define yyerrok (yyerrstatus = 0) #define yyclearin (yychar = YYEMPTY) -#define YYEMPTY (-2) +#define YYEMPTY -2 #define YYEOF 0 #define YYACCEPT goto yyacceptlab #define YYABORT goto yyabortlab -#define YYERROR goto yyerrorlab - +#define YYERROR goto yyerrlab1 /* Like YYERROR except do call yyerror. This remains here temporarily to ease the transition to the new meaning of YYERROR, for GCC. @@ -2452,71 +2413,34 @@ do \ { \ yychar = (Token); \ yylval = (Value); \ - yytoken = YYTRANSLATE (yychar); \ + yychar1 = YYTRANSLATE (yychar); \ YYPOPSTACK; \ goto yybackup; \ } \ else \ - { \ - yyerror (YY_("syntax error: cannot back up")); \ + { \ + yyerror ("syntax error: cannot back up"); \ YYERROR; \ } \ while (0) - #define YYTERROR 1 #define YYERRCODE 256 +/* YYLLOC_DEFAULT -- Compute the default location (before the actions + are run). */ -/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. - If N is 0, then set CURRENT to the empty location which ends - the previous symbol: RHS[0] (always defined). */ - -#define YYRHSLOC(Rhs, K) ((Rhs)[K]) #ifndef YYLLOC_DEFAULT -# define YYLLOC_DEFAULT(Current, Rhs, N) \ - do \ - if (N) \ - { \ - (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ - (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ - (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ - (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ - } \ - else \ - { \ - (Current).first_line = (Current).last_line = \ - YYRHSLOC (Rhs, 0).last_line; \ - (Current).first_column = (Current).last_column = \ - YYRHSLOC (Rhs, 0).last_column; \ - } \ - while (0) -#endif - - -/* YY_LOCATION_PRINT -- Print the location on the stream. - This macro was not mandated originally: define only if we know - we won't break user code: when these are the locations we know. */ - -#ifndef YY_LOCATION_PRINT -# if YYLTYPE_IS_TRIVIAL -# define YY_LOCATION_PRINT(File, Loc) \ - fprintf (File, "%d.%d-%d.%d", \ - (Loc).first_line, (Loc).first_column, \ - (Loc).last_line, (Loc).last_column) -# else -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -# endif +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + Current.first_line = Rhs[1].first_line; \ + Current.first_column = Rhs[1].first_column; \ + Current.last_line = Rhs[N].last_line; \ + Current.last_column = Rhs[N].last_column; #endif - /* YYLEX -- calling `yylex' with the right arguments. */ -#ifdef YYLEX_PARAM -# define YYLEX yylex (YYLEX_PARAM) -#else -# define YYLEX yylex () -#endif +#define YYLEX yylex () /* Enable debugging if requested. */ #if YYDEBUG @@ -2531,86 +2455,19 @@ do { \ if (yydebug) \ YYFPRINTF Args; \ } while (0) - -# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ -do { \ - if (yydebug) \ - { \ - YYFPRINTF (stderr, "%s ", Title); \ - yysymprint (stderr, \ - Type, Value); \ - YYFPRINTF (stderr, "\n"); \ - } \ -} while (0) - -/*------------------------------------------------------------------. -| yy_stack_print -- Print the state stack from its BOTTOM up to its | -| TOP (included). | -`------------------------------------------------------------------*/ - -#if defined (__STDC__) || defined (__cplusplus) -static void -yy_stack_print (short int *bottom, short int *top) -#else -static void -yy_stack_print (bottom, top) - short int *bottom; - short int *top; -#endif -{ - YYFPRINTF (stderr, "Stack now"); - for (/* Nothing. */; bottom <= top; ++bottom) - YYFPRINTF (stderr, " %d", *bottom); - YYFPRINTF (stderr, "\n"); -} - -# define YY_STACK_PRINT(Bottom, Top) \ -do { \ - if (yydebug) \ - yy_stack_print ((Bottom), (Top)); \ -} while (0) - - -/*------------------------------------------------. -| Report that the YYRULE is going to be reduced. | -`------------------------------------------------*/ - -#if defined (__STDC__) || defined (__cplusplus) -static void -yy_reduce_print (int yyrule) -#else -static void -yy_reduce_print (yyrule) - int yyrule; -#endif -{ - int yyi; - unsigned long int yylno = yyrline[yyrule]; - YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu), ", - yyrule - 1, yylno); - /* Print the symbols being reduced, and their result. */ - for (yyi = yyprhs[yyrule]; 0 <= yyrhs[yyi]; yyi++) - YYFPRINTF (stderr, "%s ", yytname[yyrhs[yyi]]); - YYFPRINTF (stderr, "-> %s\n", yytname[yyr1[yyrule]]); -} - -# define YY_REDUCE_PRINT(Rule) \ -do { \ - if (yydebug) \ - yy_reduce_print (Rule); \ +# define YYDSYMPRINT(Args) \ +do { \ + if (yydebug) \ + yysymprint Args; \ } while (0) - /* Nonzero means print parse trace. It is left uninitialized so that multiple parsers can coexist. */ int yydebug; #else /* !YYDEBUG */ # define YYDPRINTF(Args) -# define YY_SYMBOL_PRINT(Title, Type, Value, Location) -# define YY_STACK_PRINT(Bottom, Top) -# define YY_REDUCE_PRINT(Rule) +# define YYDSYMPRINT(Args) #endif /* !YYDEBUG */ - /* YYINITDEPTH -- initial size of the parser's stacks. */ #ifndef YYINITDEPTH # define YYINITDEPTH 200 @@ -2620,9 +2477,13 @@ int yydebug; if the built-in stack extension method is used). Do not make this value too large; the results are undefined if - YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH) evaluated with infinite-precision integer arithmetic. */ +#if YYMAXDEPTH == 0 +# undef YYMAXDEPTH +#endif + #ifndef YYMAXDEPTH # define YYMAXDEPTH 10000 #endif @@ -2644,7 +2505,7 @@ yystrlen (yystr) const char *yystr; # endif { - const char *yys = yystr; + register const char *yys = yystr; while (*yys++ != '\0') continue; @@ -2669,8 +2530,8 @@ yystpcpy (yydest, yysrc) const char *yysrc; # endif { - char *yyd = yydest; - const char *yys = yysrc; + register char *yyd = yydest; + register const char *yys = yysrc; while ((*yyd++ = *yys++) != '\0') continue; @@ -2680,186 +2541,124 @@ yystpcpy (yydest, yysrc) # endif # endif -# ifndef yytnamerr -/* Copy to YYRES the contents of YYSTR after stripping away unnecessary - quotes and backslashes, so that it's suitable for yyerror. The - heuristic is that double-quoting is unnecessary unless the string - contains an apostrophe, a comma, or backslash (other than - backslash-backslash). YYSTR is taken from yytname. If YYRES is - null, do not copy; instead, return the length of what the result - would have been. */ -static YYSIZE_T -yytnamerr (char *yyres, const char *yystr) -{ - if (*yystr == '"') - { - size_t yyn = 0; - char const *yyp = yystr; - - for (;;) - switch (*++yyp) - { - case '\'': - case ',': - goto do_not_strip_quotes; - - case '\\': - if (*++yyp != '\\') - goto do_not_strip_quotes; - /* Fall through. */ - default: - if (yyres) - yyres[yyn] = *yyp; - yyn++; - break; - - case '"': - if (yyres) - yyres[yyn] = '\0'; - return yyn; - } - do_not_strip_quotes: ; - } - - if (! yyres) - return yystrlen (yystr); - - return yystpcpy (yyres, yystr) - yyres; -} -# endif - -#endif /* YYERROR_VERBOSE */ +#endif /* !YYERROR_VERBOSE */ #if YYDEBUG -/*--------------------------------. -| Print this symbol on YYOUTPUT. | -`--------------------------------*/ +/*-----------------------------. +| Print this symbol on YYOUT. | +`-----------------------------*/ -#if defined (__STDC__) || defined (__cplusplus) static void -yysymprint (FILE *yyoutput, int yytype, YYSTYPE *yyvaluep) +#if defined (__STDC__) || defined (__cplusplus) +yysymprint (FILE* yyout, int yytype, YYSTYPE yyvalue) #else -static void -yysymprint (yyoutput, yytype, yyvaluep) - FILE *yyoutput; +yysymprint (yyout, yytype, yyvalue) + FILE* yyout; int yytype; - YYSTYPE *yyvaluep; + YYSTYPE yyvalue; #endif { /* Pacify ``unused variable'' warnings. */ - (void) yyvaluep; + (void) yyvalue; if (yytype < YYNTOKENS) - YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); - else - YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); - - + { + YYFPRINTF (yyout, "token %s (", yytname[yytype]); # ifdef YYPRINT - if (yytype < YYNTOKENS) - YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); + YYPRINT (yyout, yytoknum[yytype], yyvalue); # endif + } + else + YYFPRINTF (yyout, "nterm %s (", yytname[yytype]); + switch (yytype) { default: break; } - YYFPRINTF (yyoutput, ")"); + YYFPRINTF (yyout, ")"); } +#endif /* YYDEBUG. */ + -#endif /* ! YYDEBUG */ /*-----------------------------------------------. | Release the memory associated to this symbol. | `-----------------------------------------------*/ -#if defined (__STDC__) || defined (__cplusplus) static void -yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +#if defined (__STDC__) || defined (__cplusplus) +yydestruct (int yytype, YYSTYPE yyvalue) #else -static void -yydestruct (yymsg, yytype, yyvaluep) - const char *yymsg; +yydestruct (yytype, yyvalue) int yytype; - YYSTYPE *yyvaluep; + YYSTYPE yyvalue; #endif { /* Pacify ``unused variable'' warnings. */ - (void) yyvaluep; - - if (!yymsg) - yymsg = "Deleting"; - YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + (void) yyvalue; switch (yytype) { - default: break; } } + -/* Prevent warnings from -Wmissing-prototypes. */ +/* The user can define YYPARSE_PARAM as the name of an argument to be passed + into yyparse. The argument should have type void *. + It should actually point to an object. + Grammar actions can access the variable by casting it + to the proper pointer type. */ #ifdef YYPARSE_PARAM # if defined (__STDC__) || defined (__cplusplus) -int yyparse (void *YYPARSE_PARAM); +# define YYPARSE_PARAM_ARG void *YYPARSE_PARAM +# define YYPARSE_PARAM_DECL # else -int yyparse (); +# define YYPARSE_PARAM_ARG YYPARSE_PARAM +# define YYPARSE_PARAM_DECL void *YYPARSE_PARAM; # endif -#else /* ! YYPARSE_PARAM */ -#if defined (__STDC__) || defined (__cplusplus) +#else /* !YYPARSE_PARAM */ +# define YYPARSE_PARAM_ARG +# define YYPARSE_PARAM_DECL +#endif /* !YYPARSE_PARAM */ + +/* Prevent warning if -Wstrict-prototypes. */ +#ifdef __GNUC__ +# ifdef YYPARSE_PARAM +int yyparse (void *); +# else int yyparse (void); -#else -int yyparse (); +# endif #endif -#endif /* ! YYPARSE_PARAM */ - -/* The look-ahead symbol. */ +/* The lookahead symbol. */ int yychar; -/* The semantic value of the look-ahead symbol. */ +/* The semantic value of the lookahead symbol. */ YYSTYPE yylval; -/* Number of syntax errors so far. */ +/* Number of parse errors so far. */ int yynerrs; - -/*----------. -| yyparse. | -`----------*/ - -#ifdef YYPARSE_PARAM -# if defined (__STDC__) || defined (__cplusplus) -int yyparse (void *YYPARSE_PARAM) -# else -int yyparse (YYPARSE_PARAM) - void *YYPARSE_PARAM; -# endif -#else /* ! YYPARSE_PARAM */ -#if defined (__STDC__) || defined (__cplusplus) -int -yyparse (void) -#else int -yyparse () - -#endif -#endif +yyparse (YYPARSE_PARAM_ARG) + YYPARSE_PARAM_DECL { - int yystate; - int yyn; + register int yystate; + register int yyn; int yyresult; /* Number of tokens to shift before error messages enabled. */ int yyerrstatus; - /* Look-ahead token as an internal (translated) token number. */ - int yytoken = 0; + /* Lookahead token as an internal (translated) token number. */ + int yychar1 = 0; /* Three stacks and their tools: `yyss': related to states, @@ -2870,14 +2669,14 @@ yyparse () to reallocate them elsewhere. */ /* The state stack. */ - short int yyssa[YYINITDEPTH]; - short int *yyss = yyssa; - short int *yyssp; + short yyssa[YYINITDEPTH]; |