daptab.c 70 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493
  1. /* A Bison parser, made by GNU Bison 2.4.3. */
  2. /* Skeleton implementation for Bison's Yacc-like parsers in C
  3. Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
  4. 2009, 2010 Free Software Foundation, Inc.
  5. This program is free software: you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation, either version 3 of the License, or
  8. (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program. If not, see <http://www.gnu.org/licenses/>. */
  15. /* As a special exception, you may create a larger work that contains
  16. part or all of the Bison parser skeleton and distribute that work
  17. under terms of your choice, so long as that work isn't itself a
  18. parser generator using the skeleton or a modified version thereof
  19. as a parser skeleton. Alternatively, if you modify or redistribute
  20. the parser skeleton itself, you may (at your option) remove this
  21. special exception, which will cause the skeleton and the resulting
  22. Bison output files to be licensed under the GNU General Public
  23. License without this special exception.
  24. This special exception was added by the Free Software Foundation in
  25. version 2.2 of Bison. */
  26. /* C LALR(1) parser skeleton written by Richard Stallman, by
  27. simplifying the original so-called "semantic" parser. */
  28. /* All symbols defined below should begin with yy or YY, to avoid
  29. infringing on user name space. This should be done even for local
  30. variables, as they might otherwise be expanded by user macros.
  31. There are some unavoidable exceptions within include files to
  32. define necessary library symbols; they are noted "INFRINGES ON
  33. USER NAME SPACE" below. */
  34. /* Identify Bison output. */
  35. #define YYBISON 1
  36. /* Bison version. */
  37. #define YYBISON_VERSION "2.4.3"
  38. /* Skeleton name. */
  39. #define YYSKELETON_NAME "yacc.c"
  40. /* Pure parsers. */
  41. #define YYPURE 1
  42. /* Push parsers. */
  43. #define YYPUSH 0
  44. /* Pull parsers. */
  45. #define YYPULL 1
  46. /* Using locations. */
  47. #define YYLSP_NEEDED 0
  48. /* Substitute the variable and function names. */
  49. #define yyparse dapparse
  50. #define yylex daplex
  51. #define yyerror daperror
  52. #define yylval daplval
  53. #define yychar dapchar
  54. #define yydebug dapdebug
  55. #define yynerrs dapnerrs
  56. /* Copy the first part of user declarations. */
  57. /* Line 189 of yacc.c */
  58. #line 11 "dap.y"
  59. #include "config.h"
  60. #include "dapparselex.h"
  61. int dapdebug = 0;
  62. /* Line 189 of yacc.c */
  63. #line 87 "dap.tab.c"
  64. /* Enabling traces. */
  65. #ifndef YYDEBUG
  66. # define YYDEBUG 1
  67. #endif
  68. /* Enabling verbose error messages. */
  69. #ifdef YYERROR_VERBOSE
  70. # undef YYERROR_VERBOSE
  71. # define YYERROR_VERBOSE 1
  72. #else
  73. # define YYERROR_VERBOSE 1
  74. #endif
  75. /* Enabling the token table. */
  76. #ifndef YYTOKEN_TABLE
  77. # define YYTOKEN_TABLE 0
  78. #endif
  79. /* Tokens. */
  80. #ifndef YYTOKENTYPE
  81. # define YYTOKENTYPE
  82. /* Put the tokens into the symbol table, so that GDB and other debuggers
  83. know about them. */
  84. enum yytokentype {
  85. SCAN_ALIAS = 258,
  86. SCAN_ARRAY = 259,
  87. SCAN_ATTR = 260,
  88. SCAN_BYTE = 261,
  89. SCAN_CODE = 262,
  90. SCAN_DATASET = 263,
  91. SCAN_DATA = 264,
  92. SCAN_ERROR = 265,
  93. SCAN_FLOAT32 = 266,
  94. SCAN_FLOAT64 = 267,
  95. SCAN_GRID = 268,
  96. SCAN_INT16 = 269,
  97. SCAN_INT32 = 270,
  98. SCAN_MAPS = 271,
  99. SCAN_MESSAGE = 272,
  100. SCAN_SEQUENCE = 273,
  101. SCAN_STRING = 274,
  102. SCAN_STRUCTURE = 275,
  103. SCAN_UINT16 = 276,
  104. SCAN_UINT32 = 277,
  105. SCAN_URL = 278,
  106. SCAN_PTYPE = 279,
  107. SCAN_PROG = 280,
  108. WORD_WORD = 281,
  109. WORD_STRING = 282
  110. };
  111. #endif
  112. #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
  113. typedef int YYSTYPE;
  114. # define YYSTYPE_IS_TRIVIAL 1
  115. # define yystype YYSTYPE /* obsolescent; will be withdrawn */
  116. # define YYSTYPE_IS_DECLARED 1
  117. #endif
  118. /* Copy the second part of user declarations. */
  119. /* Line 264 of yacc.c */
  120. #line 156 "dap.tab.c"
  121. #ifdef short
  122. # undef short
  123. #endif
  124. #ifdef YYTYPE_UINT8
  125. typedef YYTYPE_UINT8 yytype_uint8;
  126. #else
  127. typedef unsigned char yytype_uint8;
  128. #endif
  129. #ifdef YYTYPE_INT8
  130. typedef YYTYPE_INT8 yytype_int8;
  131. #elif (defined __STDC__ || defined __C99__FUNC__ \
  132. || defined __cplusplus || defined _MSC_VER)
  133. typedef signed char yytype_int8;
  134. #else
  135. typedef short int yytype_int8;
  136. #endif
  137. #ifdef YYTYPE_UINT16
  138. typedef YYTYPE_UINT16 yytype_uint16;
  139. #else
  140. typedef unsigned short int yytype_uint16;
  141. #endif
  142. #ifdef YYTYPE_INT16
  143. typedef YYTYPE_INT16 yytype_int16;
  144. #else
  145. typedef short int yytype_int16;
  146. #endif
  147. #ifndef YYSIZE_T
  148. # ifdef __SIZE_TYPE__
  149. # define YYSIZE_T __SIZE_TYPE__
  150. # elif defined size_t
  151. # define YYSIZE_T size_t
  152. # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
  153. || defined __cplusplus || defined _MSC_VER)
  154. # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
  155. # define YYSIZE_T size_t
  156. # else
  157. # define YYSIZE_T unsigned int
  158. # endif
  159. #endif
  160. #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
  161. #ifndef YY_
  162. # if defined YYENABLE_NLS && YYENABLE_NLS
  163. # if ENABLE_NLS
  164. # include <libintl.h> /* INFRINGES ON USER NAME SPACE */
  165. # define YY_(msgid) dgettext ("bison-runtime", msgid)
  166. # endif
  167. # endif
  168. # ifndef YY_
  169. # define YY_(msgid) msgid
  170. # endif
  171. #endif
  172. /* Suppress unused-variable warnings by "using" E. */
  173. #if ! defined lint || defined __GNUC__
  174. # define YYUSE(e) ((void) (e))
  175. #else
  176. # define YYUSE(e) /* empty */
  177. #endif
  178. /* Identity function, used to suppress warnings about constant conditions. */
  179. #ifndef lint
  180. # define YYID(n) (n)
  181. #else
  182. #if (defined __STDC__ || defined __C99__FUNC__ \
  183. || defined __cplusplus || defined _MSC_VER)
  184. static int
  185. YYID (int yyi)
  186. #else
  187. static int
  188. YYID (yyi)
  189. int yyi;
  190. #endif
  191. {
  192. return yyi;
  193. }
  194. #endif
  195. #if ! defined yyoverflow || YYERROR_VERBOSE
  196. /* The parser invokes alloca or malloc; define the necessary symbols. */
  197. # ifdef YYSTACK_USE_ALLOCA
  198. # if YYSTACK_USE_ALLOCA
  199. # ifdef __GNUC__
  200. # define YYSTACK_ALLOC __builtin_alloca
  201. # elif defined __BUILTIN_VA_ARG_INCR
  202. # include <alloca.h> /* INFRINGES ON USER NAME SPACE */
  203. # elif defined _AIX
  204. # define YYSTACK_ALLOC __alloca
  205. # elif defined _MSC_VER
  206. # include <malloc.h> /* INFRINGES ON USER NAME SPACE */
  207. # define alloca _alloca
  208. # else
  209. # define YYSTACK_ALLOC alloca
  210. # if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
  211. || defined __cplusplus || defined _MSC_VER)
  212. # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
  213. # ifndef _STDLIB_H
  214. # define _STDLIB_H 1
  215. # endif
  216. # endif
  217. # endif
  218. # endif
  219. # endif
  220. # ifdef YYSTACK_ALLOC
  221. /* Pacify GCC's `empty if-body' warning. */
  222. # define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
  223. # ifndef YYSTACK_ALLOC_MAXIMUM
  224. /* The OS might guarantee only one guard page at the bottom of the stack,
  225. and a page size can be as small as 4096 bytes. So we cannot safely
  226. invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
  227. to allow for a few compiler-allocated temporary stack slots. */
  228. # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
  229. # endif
  230. # else
  231. # define YYSTACK_ALLOC YYMALLOC
  232. # define YYSTACK_FREE YYFREE
  233. # ifndef YYSTACK_ALLOC_MAXIMUM
  234. # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
  235. # endif
  236. # if (defined __cplusplus && ! defined _STDLIB_H \
  237. && ! ((defined YYMALLOC || defined malloc) \
  238. && (defined YYFREE || defined free)))
  239. # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
  240. # ifndef _STDLIB_H
  241. # define _STDLIB_H 1
  242. # endif
  243. # endif
  244. # ifndef YYMALLOC
  245. # define YYMALLOC malloc
  246. # if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
  247. || defined __cplusplus || defined _MSC_VER)
  248. void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
  249. # endif
  250. # endif
  251. # ifndef YYFREE
  252. # define YYFREE free
  253. # if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
  254. || defined __cplusplus || defined _MSC_VER)
  255. void free (void *); /* INFRINGES ON USER NAME SPACE */
  256. # endif
  257. # endif
  258. # endif
  259. #endif /* ! defined yyoverflow || YYERROR_VERBOSE */
  260. #if (! defined yyoverflow \
  261. && (! defined __cplusplus \
  262. || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
  263. /* A type that is properly aligned for any stack member. */
  264. union yyalloc
  265. {
  266. yytype_int16 yyss_alloc;
  267. YYSTYPE yyvs_alloc;
  268. };
  269. /* The size of the maximum gap between one aligned stack and the next. */
  270. # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
  271. /* The size of an array large to enough to hold all stacks, each with
  272. N elements. */
  273. # define YYSTACK_BYTES(N) \
  274. ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
  275. + YYSTACK_GAP_MAXIMUM)
  276. /* Copy COUNT objects from FROM to TO. The source and destination do
  277. not overlap. */
  278. # ifndef YYCOPY
  279. # if defined __GNUC__ && 1 < __GNUC__
  280. # define YYCOPY(To, From, Count) \
  281. __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
  282. # else
  283. # define YYCOPY(To, From, Count) \
  284. do \
  285. { \
  286. YYSIZE_T yyi; \
  287. for (yyi = 0; yyi < (Count); yyi++) \
  288. (To)[yyi] = (From)[yyi]; \
  289. } \
  290. while (YYID (0))
  291. # endif
  292. # endif
  293. /* Relocate STACK from its old location to the new one. The
  294. local variables YYSIZE and YYSTACKSIZE give the old and new number of
  295. elements in the stack, and YYPTR gives the new location of the
  296. stack. Advance YYPTR to a properly aligned location for the next
  297. stack. */
  298. # define YYSTACK_RELOCATE(Stack_alloc, Stack) \
  299. do \
  300. { \
  301. YYSIZE_T yynewbytes; \
  302. YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
  303. Stack = &yyptr->Stack_alloc; \
  304. yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
  305. yyptr += yynewbytes / sizeof (*yyptr); \
  306. } \
  307. while (YYID (0))
  308. #endif
  309. /* YYFINAL -- State number of the termination state. */
  310. #define YYFINAL 9
  311. /* YYLAST -- Last index in YYTABLE. */
  312. #define YYLAST 361
  313. /* YYNTOKENS -- Number of terminals. */
  314. #define YYNTOKENS 36
  315. /* YYNNTS -- Number of nonterminals. */
  316. #define YYNNTS 34
  317. /* YYNRULES -- Number of rules. */
  318. #define YYNRULES 106
  319. /* YYNRULES -- Number of states. */
  320. #define YYNSTATES 201
  321. /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
  322. #define YYUNDEFTOK 2
  323. #define YYMAXUTOK 282
  324. #define YYTRANSLATE(YYX) \
  325. ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
  326. /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
  327. static const yytype_uint8 yytranslate[] =
  328. {
  329. 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  330. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  331. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  332. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  333. 2, 2, 2, 2, 35, 2, 2, 2, 2, 2,
  334. 2, 2, 2, 2, 2, 2, 2, 2, 31, 30,
  335. 2, 34, 2, 2, 2, 2, 2, 2, 2, 2,
  336. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  337. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  338. 2, 32, 2, 33, 2, 2, 2, 2, 2, 2,
  339. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  340. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  341. 2, 2, 2, 28, 2, 29, 2, 2, 2, 2,
  342. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  343. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  344. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  345. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  346. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  347. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  348. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  349. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  350. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  351. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  352. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  353. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  354. 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
  355. 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
  356. 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
  357. 25, 26, 27
  358. };
  359. #if YYDEBUG
  360. /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
  361. YYRHS. */
  362. static const yytype_uint16 yyprhs[] =
  363. {
  364. 0, 0, 3, 6, 10, 13, 16, 18, 20, 22,
  365. 24, 30, 31, 34, 39, 47, 54, 66, 68, 70,
  366. 72, 74, 76, 78, 80, 82, 84, 86, 87, 90,
  367. 94, 99, 105, 107, 109, 111, 113, 117, 119, 120,
  368. 123, 126, 131, 136, 141, 146, 151, 156, 161, 166,
  369. 171, 176, 178, 180, 184, 186, 190, 192, 196, 198,
  370. 202, 204, 208, 210, 214, 216, 220, 222, 226, 228,
  371. 232, 234, 236, 238, 242, 250, 251, 256, 257, 262,
  372. 263, 268, 269, 274, 276, 278, 280, 282, 284, 286,
  373. 288, 290, 292, 294, 296, 298, 300, 302, 304, 306,
  374. 308, 310, 312, 314, 316, 318, 320
  375. };
  376. /* YYRHS -- A `-1'-separated list of the rules' RHS. */
  377. static const yytype_int8 yyrhs[] =
  378. {
  379. 37, 0, -1, 38, 41, -1, 38, 41, 9, -1,
  380. 39, 49, -1, 40, 64, -1, 1, -1, 8, -1,
  381. 5, -1, 10, -1, 28, 42, 29, 47, 30, -1,
  382. -1, 42, 43, -1, 44, 48, 45, 30, -1, 20,
  383. 28, 42, 29, 48, 45, 30, -1, 18, 28, 42,
  384. 29, 48, 30, -1, 13, 28, 4, 31, 43, 16,
  385. 31, 42, 29, 48, 30, -1, 1, -1, 6, -1,
  386. 14, -1, 21, -1, 15, -1, 22, -1, 11, -1,
  387. 12, -1, 23, -1, 19, -1, -1, 45, 46, -1,
  388. 32, 26, 33, -1, 32, 34, 26, 33, -1, 32,
  389. 69, 34, 26, 33, -1, 1, -1, 48, -1, 1,
  390. -1, 69, -1, 28, 50, 29, -1, 1, -1, -1,
  391. 50, 51, -1, 63, 30, -1, 6, 69, 52, 30,
  392. -1, 14, 69, 53, 30, -1, 21, 69, 54, 30,
  393. -1, 15, 69, 55, 30, -1, 22, 69, 56, 30,
  394. -1, 11, 69, 57, 30, -1, 12, 69, 58, 30,
  395. -1, 19, 69, 59, 30, -1, 23, 69, 60, 30,
  396. -1, 69, 28, 50, 29, -1, 1, -1, 26, -1,
  397. 52, 35, 26, -1, 26, -1, 53, 35, 26, -1,
  398. 26, -1, 54, 35, 26, -1, 26, -1, 55, 35,
  399. 26, -1, 26, -1, 56, 35, 26, -1, 26, -1,
  400. 57, 35, 26, -1, 26, -1, 58, 35, 26, -1,
  401. 62, -1, 59, 35, 62, -1, 61, -1, 60, 35,
  402. 61, -1, 69, -1, 69, -1, 27, -1, 3, 26,
  403. 26, -1, 28, 65, 66, 67, 68, 29, 30, -1,
  404. -1, 7, 34, 26, 30, -1, -1, 17, 34, 26,
  405. 30, -1, -1, 24, 34, 26, 30, -1, -1, 25,
  406. 34, 26, 30, -1, 26, -1, 3, -1, 4, -1,
  407. 5, -1, 6, -1, 8, -1, 9, -1, 10, -1,
  408. 11, -1, 12, -1, 13, -1, 14, -1, 15, -1,
  409. 16, -1, 18, -1, 19, -1, 20, -1, 21, -1,
  410. 22, -1, 23, -1, 7, -1, 17, -1, 25, -1,
  411. 24, -1
  412. };
  413. /* YYRLINE[YYN] -- source line where rule number YYN was defined. */
  414. static const yytype_uint16 yyrline[] =
  415. {
  416. 0, 53, 53, 54, 55, 56, 57, 61, 65, 69,
  417. 74, 80, 81, 87, 89, 91, 93, 96, 102, 103,
  418. 104, 105, 106, 107, 108, 109, 110, 114, 115, 119,
  419. 120, 121, 122, 127, 128, 132, 135, 136, 141, 142,
  420. 146, 147, 149, 151, 153, 155, 157, 159, 161, 163,
  421. 165, 166, 171, 172, 176, 177, 181, 182, 186, 187,
  422. 191, 192, 195, 196, 199, 200, 203, 204, 208, 209,
  423. 213, 217, 218, 229, 233, 237, 237, 238, 238, 239,
  424. 239, 240, 240, 246, 247, 248, 249, 250, 251, 252,
  425. 253, 254, 255, 256, 257, 258, 259, 260, 261, 262,
  426. 263, 264, 265, 266, 267, 268, 269
  427. };
  428. #endif
  429. #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
  430. /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
  431. First, the terminals, then, starting at YYNTOKENS, nonterminals. */
  432. static const char *const yytname[] =
  433. {
  434. "$end", "error", "$undefined", "SCAN_ALIAS", "SCAN_ARRAY", "SCAN_ATTR",
  435. "SCAN_BYTE", "SCAN_CODE", "SCAN_DATASET", "SCAN_DATA", "SCAN_ERROR",
  436. "SCAN_FLOAT32", "SCAN_FLOAT64", "SCAN_GRID", "SCAN_INT16", "SCAN_INT32",
  437. "SCAN_MAPS", "SCAN_MESSAGE", "SCAN_SEQUENCE", "SCAN_STRING",
  438. "SCAN_STRUCTURE", "SCAN_UINT16", "SCAN_UINT32", "SCAN_URL", "SCAN_PTYPE",
  439. "SCAN_PROG", "WORD_WORD", "WORD_STRING", "'{'", "'}'", "';'", "':'",
  440. "'['", "']'", "'='", "','", "$accept", "start", "dataset", "attr", "err",
  441. "datasetbody", "declarations", "declaration", "base_type", "array_decls",
  442. "array_decl", "datasetname", "var_name", "attributebody", "attr_list",
  443. "attribute", "bytes", "int16", "uint16", "int32", "uint32", "float32",
  444. "float64", "strs", "urls", "url", "str_or_id", "alias", "errorbody",
  445. "errorcode", "errormsg", "errorptype", "errorprog", "name", 0
  446. };
  447. #endif
  448. # ifdef YYPRINT
  449. /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
  450. token YYLEX-NUM. */
  451. static const yytype_uint16 yytoknum[] =
  452. {
  453. 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
  454. 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
  455. 275, 276, 277, 278, 279, 280, 281, 282, 123, 125,
  456. 59, 58, 91, 93, 61, 44
  457. };
  458. # endif
  459. /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
  460. static const yytype_uint8 yyr1[] =
  461. {
  462. 0, 36, 37, 37, 37, 37, 37, 38, 39, 40,
  463. 41, 42, 42, 43, 43, 43, 43, 43, 44, 44,
  464. 44, 44, 44, 44, 44, 44, 44, 45, 45, 46,
  465. 46, 46, 46, 47, 47, 48, 49, 49, 50, 50,
  466. 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
  467. 51, 51, 52, 52, 53, 53, 54, 54, 55, 55,
  468. 56, 56, 57, 57, 58, 58, 59, 59, 60, 60,
  469. 61, 62, 62, 63, 64, 65, 65, 66, 66, 67,
  470. 67, 68, 68, 69, 69, 69, 69, 69, 69, 69,
  471. 69, 69, 69, 69, 69, 69, 69, 69, 69, 69,
  472. 69, 69, 69, 69, 69, 69, 69
  473. };
  474. /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
  475. static const yytype_uint8 yyr2[] =
  476. {
  477. 0, 2, 2, 3, 2, 2, 1, 1, 1, 1,
  478. 5, 0, 2, 4, 7, 6, 11, 1, 1, 1,
  479. 1, 1, 1, 1, 1, 1, 1, 0, 2, 3,
  480. 4, 5, 1, 1, 1, 1, 3, 1, 0, 2,
  481. 2, 4, 4, 4, 4, 4, 4, 4, 4, 4,
  482. 4, 1, 1, 3, 1, 3, 1, 3, 1, 3,
  483. 1, 3, 1, 3, 1, 3, 1, 3, 1, 3,
  484. 1, 1, 1, 3, 7, 0, 4, 0, 4, 0,
  485. 4, 0, 4, 1, 1, 1, 1, 1, 1, 1,
  486. 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
  487. 1, 1, 1, 1, 1, 1, 1
  488. };
  489. /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
  490. STATE-NUM when YYTABLE doesn't specify something else to do. Zero
  491. means the default is an error. */
  492. static const yytype_uint8 yydefact[] =
  493. {
  494. 0, 6, 8, 7, 9, 0, 0, 0, 0, 1,
  495. 11, 2, 37, 38, 4, 75, 5, 0, 3, 0,
  496. 0, 77, 17, 18, 23, 24, 0, 19, 21, 0,
  497. 26, 0, 20, 22, 25, 0, 12, 0, 51, 84,
  498. 85, 86, 87, 103, 88, 89, 90, 91, 92, 93,
  499. 94, 95, 96, 104, 97, 98, 99, 100, 101, 102,
  500. 106, 105, 83, 36, 39, 0, 0, 0, 0, 79,
  501. 0, 11, 11, 34, 84, 87, 91, 92, 94, 95,
  502. 98, 100, 101, 102, 0, 33, 35, 27, 0, 0,
  503. 0, 0, 0, 0, 0, 0, 0, 0, 40, 38,
  504. 0, 0, 0, 81, 0, 0, 0, 10, 0, 73,
  505. 52, 0, 62, 0, 64, 0, 54, 0, 58, 0,
  506. 72, 0, 66, 71, 56, 0, 60, 0, 0, 68,
  507. 70, 0, 76, 0, 0, 0, 0, 0, 0, 0,
  508. 32, 13, 0, 28, 41, 0, 46, 0, 47, 0,
  509. 42, 0, 44, 0, 48, 0, 43, 0, 45, 0,
  510. 49, 0, 50, 78, 0, 0, 0, 0, 0, 27,
  511. 83, 0, 0, 53, 63, 65, 55, 59, 67, 57,
  512. 61, 69, 80, 0, 74, 0, 15, 0, 29, 0,
  513. 0, 82, 11, 14, 30, 0, 0, 31, 0, 0,
  514. 16
  515. };
  516. /* YYDEFGOTO[NTERM-NUM]. */
  517. static const yytype_int16 yydefgoto[] =
  518. {
  519. -1, 5, 6, 7, 8, 11, 17, 36, 37, 108,
  520. 143, 84, 85, 14, 19, 64, 111, 117, 125, 119,
  521. 127, 113, 115, 121, 128, 129, 122, 65, 16, 21,
  522. 69, 103, 136, 86
  523. };
  524. /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
  525. STATE-NUM. */
  526. #define YYPACT_NINF -70
  527. static const yytype_int16 yypact[] =
  528. {
  529. 5, -70, -70, -70, -70, 8, -1, 3, 0, -70,
  530. -70, 10, -70, -70, -70, 28, -70, 69, -70, 159,
  531. 34, 57, -70, -70, -70, -70, 50, -70, -70, 58,
  532. -70, 65, -70, -70, -70, 263, -70, 312, -70, 59,
  533. -70, -70, 312, -70, -70, -70, -70, 312, 312, -70,
  534. 312, 312, -70, -70, -70, 312, -70, 312, 312, 312,
  535. -70, -70, -70, -70, -70, 64, 67, 70, 63, 75,
  536. 96, -70, -70, -70, -70, -70, -70, -70, -70, -70,
  537. -70, -70, -70, -70, 73, -70, -70, -70, 78, 79,
  538. 80, 81, 82, 83, 287, 84, 85, 312, -70, -70,
  539. 86, 88, 87, 90, 89, 127, 212, -70, 4, -70,
  540. -70, -23, -70, -21, -70, -19, -70, -13, -70, -12,
  541. -70, -10, -70, -70, -70, -9, -70, 36, 42, -70,
  542. -70, 186, -70, 92, 91, 93, 97, 338, 312, 312,
  543. -70, -70, 39, -70, -70, 99, -70, 103, -70, 104,
  544. -70, 105, -70, 106, -70, 287, -70, 108, -70, 109,
  545. -70, 312, -70, -70, 114, 110, 121, 102, 122, -70,
  546. 120, 128, 123, -70, -70, -70, -70, -70, -70, -70,
  547. -70, -70, -70, 125, -70, 155, -70, 37, -70, 126,
  548. 132, -70, -70, -70, -70, 181, 236, -70, 312, 187,
  549. -70
  550. };
  551. /* YYPGOTO[NTERM-NUM]. */
  552. static const yytype_int8 yypgoto[] =
  553. {
  554. -70, -70, -70, -70, -70, -70, -69, -25, -70, -50,
  555. -70, -70, -37, -70, 117, -70, -70, -70, -70, -70,
  556. -70, -70, -70, -70, -70, 60, 74, -70, -70, -70,
  557. -70, -70, -70, -18
  558. };
  559. /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
  560. positive, shift that token. If negative, reduce the rule which
  561. number is the opposite. If zero, do what YYDEFACT says.
  562. If YYTABLE_NINF, syntax error. */
  563. #define YYTABLE_NINF -1
  564. static const yytype_uint8 yytable[] =
  565. {
  566. 87, 66, 105, 106, 12, 140, 1, 144, 9, 146,
  567. 2, 148, 145, 3, 147, 4, 149, 150, 152, 18,
  568. 154, 156, 151, 153, 89, 155, 157, 10, 15, 90,
  569. 91, 13, 92, 93, 141, 20, 142, 94, 140, 95,
  570. 96, 97, 74, 40, 41, 75, 43, 44, 45, 46,
  571. 76, 77, 49, 78, 79, 52, 53, 54, 80, 56,
  572. 81, 82, 83, 60, 61, 170, 158, 193, 67, 142,
  573. 22, 159, 160, 171, 68, 23, 123, 161, 70, 130,
  574. 24, 25, 26, 27, 28, 88, 71, 29, 30, 31,
  575. 32, 33, 34, 72, 98, 99, 100, 101, 35, 102,
  576. 104, 168, 169, 107, 109, 110, 112, 114, 116, 118,
  577. 124, 126, 167, 66, 133, 135, 132, 164, 185, 187,
  578. 137, 134, 163, 196, 172, 173, 166, 165, 22, 174,
  579. 175, 176, 177, 23, 179, 180, 183, 123, 24, 25,
  580. 26, 27, 28, 130, 182, 29, 30, 31, 32, 33,
  581. 34, 184, 186, 188, 189, 191, 138, 190, 195, 194,
  582. 38, 199, 39, 40, 41, 42, 43, 44, 45, 46,
  583. 47, 48, 49, 50, 51, 52, 53, 54, 55, 56,
  584. 57, 58, 59, 60, 61, 62, 192, 38, 63, 39,
  585. 40, 41, 42, 43, 44, 45, 46, 47, 48, 49,
  586. 50, 51, 52, 53, 54, 55, 56, 57, 58, 59,
  587. 60, 61, 62, 22, 197, 162, 131, 200, 23, 0,
  588. 0, 181, 0, 24, 25, 26, 27, 28, 0, 178,
  589. 29, 30, 31, 32, 33, 34, 0, 22, 0, 0,
  590. 0, 139, 23, 0, 0, 0, 0, 24, 25, 26,
  591. 27, 28, 0, 0, 29, 30, 31, 32, 33, 34,
  592. 0, 0, 0, 0, 73, 198, 74, 40, 41, 75,
  593. 43, 44, 45, 46, 76, 77, 49, 78, 79, 52,
  594. 53, 54, 80, 56, 81, 82, 83, 60, 61, 62,
  595. 74, 40, 41, 75, 43, 44, 45, 46, 76, 77,
  596. 49, 78, 79, 52, 53, 54, 80, 56, 81, 82,
  597. 83, 60, 61, 62, 120, 74, 40, 41, 75, 43,
  598. 44, 45, 46, 76, 77, 49, 78, 79, 52, 53,
  599. 54, 80, 56, 81, 82, 83, 60, 61, 62, 22,
  600. 0, 0, 0, 0, 23, 0, 0, 0, 0, 24,
  601. 25, 26, 27, 28, 0, 0, 29, 30, 31, 32,
  602. 33, 34
  603. };
  604. static const yytype_int16 yycheck[] =
  605. {
  606. 37, 19, 71, 72, 1, 1, 1, 30, 0, 30,
  607. 5, 30, 35, 8, 35, 10, 35, 30, 30, 9,
  608. 30, 30, 35, 35, 42, 35, 35, 28, 28, 47,
  609. 48, 28, 50, 51, 30, 7, 32, 55, 1, 57,
  610. 58, 59, 3, 4, 5, 6, 7, 8, 9, 10,
  611. 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
  612. 21, 22, 23, 24, 25, 26, 30, 30, 34, 32,
  613. 1, 35, 30, 34, 17, 6, 94, 35, 28, 97,
  614. 11, 12, 13, 14, 15, 26, 28, 18, 19, 20,
  615. 21, 22, 23, 28, 30, 28, 26, 34, 29, 24,
  616. 4, 138, 139, 30, 26, 26, 26, 26, 26, 26,
  617. 26, 26, 137, 131, 26, 25, 30, 26, 16, 169,
  618. 31, 34, 30, 192, 142, 26, 29, 34, 1, 26,
  619. 26, 26, 26, 6, 26, 26, 26, 155, 11, 12,
  620. 13, 14, 15, 161, 30, 18, 19, 20, 21, 22,
  621. 23, 30, 30, 33, 26, 30, 29, 34, 26, 33,
  622. 1, 198, 3, 4, 5, 6, 7, 8, 9, 10,
  623. 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
  624. 21, 22, 23, 24, 25, 26, 31, 1, 29, 3,
  625. 4, 5, 6, 7, 8, 9, 10, 11, 12, 13,
  626. 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
  627. 24, 25, 26, 1, 33, 29, 99, 30, 6, -1,
  628. -1, 161, -1, 11, 12, 13, 14, 15, -1, 155,
  629. 18, 19, 20, 21, 22, 23, -1, 1, -1, -1,
  630. -1, 29, 6, -1, -1, -1, -1, 11, 12, 13,
  631. 14, 15, -1, -1, 18, 19, 20, 21, 22, 23,
  632. -1, -1, -1, -1, 1, 29, 3, 4, 5, 6,
  633. 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
  634. 17, 18, 19, 20, 21, 22, 23, 24, 25, 26,
  635. 3, 4, 5, 6, 7, 8, 9, 10, 11, 12,
  636. 13, 14, 15, 16, 17, 18, 19, 20, 21, 22,
  637. 23, 24, 25, 26, 27, 3, 4, 5, 6, 7,
  638. 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
  639. 18, 19, 20, 21, 22, 23, 24, 25, 26, 1,
  640. -1, -1, -1, -1, 6, -1, -1, -1, -1, 11,
  641. 12, 13, 14, 15, -1, -1, 18, 19, 20, 21,
  642. 22, 23
  643. };
  644. /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
  645. symbol of state STATE-NUM. */
  646. static const yytype_uint8 yystos[] =
  647. {
  648. 0, 1, 5, 8, 10, 37, 38, 39, 40, 0,
  649. 28, 41, 1, 28, 49, 28, 64, 42, 9, 50,
  650. 7, 65, 1, 6, 11, 12, 13, 14, 15, 18,
  651. 19, 20, 21, 22, 23, 29, 43, 44, 1, 3,
  652. 4, 5, 6, 7, 8, 9, 10, 11, 12, 13,
  653. 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
  654. 24, 25, 26, 29, 51, 63, 69, 34, 17, 66,
  655. 28, 28, 28, 1, 3, 6, 11, 12, 14, 15,
  656. 19, 21, 22, 23, 47, 48, 69, 48, 26, 69,
  657. 69, 69, 69, 69, 69, 69, 69, 69, 30, 28,
  658. 26, 34, 24, 67, 4, 42, 42, 30, 45, 26,
  659. 26, 52, 26, 57, 26, 58, 26, 53, 26, 55,
  660. 27, 59, 62, 69, 26, 54, 26, 56, 60, 61,
  661. 69, 50, 30, 26, 34, 25, 68, 31, 29, 29,
  662. 1, 30, 32, 46, 30, 35, 30, 35, 30, 35,
  663. 30, 35, 30, 35, 30, 35, 30, 35, 30, 35,
  664. 30, 35, 29, 30, 26, 34, 29, 43, 48, 48,
  665. 26, 34, 69, 26, 26, 26, 26, 26, 62, 26,
  666. 26, 61, 30, 26, 30, 16, 30, 45, 33, 26,
  667. 34, 30, 31, 30, 33, 26, 42, 33, 29, 48,
  668. 30
  669. };
  670. #define yyerrok (yyerrstatus = 0)
  671. #define yyclearin (yychar = YYEMPTY)
  672. #define YYEMPTY (-2)
  673. #define YYEOF 0
  674. #define YYACCEPT goto yyacceptlab
  675. #define YYABORT goto yyabortlab
  676. #define YYERROR goto yyerrorlab
  677. /* Like YYERROR except do call yyerror. This remains here temporarily
  678. to ease the transition to the new meaning of YYERROR, for GCC.
  679. Once GCC version 2 has supplanted version 1, this can go. However,
  680. YYFAIL appears to be in use. Nevertheless, it is formally deprecated
  681. in Bison 2.4.2's NEWS entry, where a plan to phase it out is
  682. discussed. */
  683. #define YYFAIL goto yyerrlab
  684. #if defined YYFAIL
  685. /* This is here to suppress warnings from the GCC cpp's
  686. -Wunused-macros. Normally we don't worry about that warning, but
  687. some users do, and we want to make it easy for users to remove
  688. YYFAIL uses, which will produce warnings from Bison 2.5. */
  689. #endif
  690. #define YYRECOVERING() (!!yyerrstatus)
  691. #define YYBACKUP(Token, Value) \
  692. do \
  693. if (yychar == YYEMPTY && yylen == 1) \
  694. { \
  695. yychar = (Token); \
  696. yylval = (Value); \
  697. yytoken = YYTRANSLATE (yychar); \
  698. YYPOPSTACK (1); \
  699. goto yybackup; \
  700. } \
  701. else \
  702. { \
  703. yyerror (parsestate, YY_("syntax error: cannot back up")); \
  704. YYERROR; \
  705. } \
  706. while (YYID (0))
  707. #define YYTERROR 1
  708. #define YYERRCODE 256
  709. /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
  710. If N is 0, then set CURRENT to the empty location which ends
  711. the previous symbol: RHS[0] (always defined). */
  712. #define YYRHSLOC(Rhs, K) ((Rhs)[K])
  713. #ifndef YYLLOC_DEFAULT
  714. # define YYLLOC_DEFAULT(Current, Rhs, N) \
  715. do \
  716. if (YYID (N)) \
  717. { \
  718. (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
  719. (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
  720. (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
  721. (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
  722. } \
  723. else \
  724. { \
  725. (Current).first_line = (Current).last_line = \
  726. YYRHSLOC (Rhs, 0).last_line; \
  727. (Current).first_column = (Current).last_column = \
  728. YYRHSLOC (Rhs, 0).last_column; \
  729. } \
  730. while (YYID (0))
  731. #endif
  732. /* YY_LOCATION_PRINT -- Print the location on the stream.
  733. This macro was not mandated originally: define only if we know
  734. we won't break user code: when these are the locations we know. */
  735. #ifndef YY_LOCATION_PRINT
  736. # if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
  737. # define YY_LOCATION_PRINT(File, Loc) \
  738. fprintf (File, "%d.%d-%d.%d", \
  739. (Loc).first_line, (Loc).first_column, \
  740. (Loc).last_line, (Loc).last_column)
  741. # else
  742. # define YY_LOCATION_PRINT(File, Loc) ((void) 0)
  743. # endif
  744. #endif
  745. /* YYLEX -- calling `yylex' with the right arguments. */
  746. #ifdef YYLEX_PARAM
  747. # define YYLEX yylex (&yylval, YYLEX_PARAM)
  748. #else
  749. # define YYLEX yylex (&yylval, parsestate)
  750. #endif
  751. /* Enable debugging if requested. */
  752. #if YYDEBUG
  753. # ifndef YYFPRINTF
  754. # include <stdio.h> /* INFRINGES ON USER NAME SPACE */
  755. # define YYFPRINTF fprintf
  756. # endif
  757. # define YYDPRINTF(Args) \
  758. do { \
  759. if (yydebug) \
  760. YYFPRINTF Args; \
  761. } while (YYID (0))
  762. # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
  763. do { \
  764. if (yydebug) \
  765. { \
  766. YYFPRINTF (stderr, "%s ", Title); \
  767. yy_symbol_print (stderr, \
  768. Type, Value, parsestate); \
  769. YYFPRINTF (stderr, "\n"); \
  770. } \
  771. } while (YYID (0))
  772. /*--------------------------------.
  773. | Print this symbol on YYOUTPUT. |
  774. `--------------------------------*/
  775. /*ARGSUSED*/
  776. #if (defined __STDC__ || defined __C99__FUNC__ \
  777. || defined __cplusplus || defined _MSC_VER)
  778. static void
  779. yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, DAPparsestate* parsestate)
  780. #else
  781. static void
  782. yy_symbol_value_print (yyoutput, yytype, yyvaluep, parsestate)
  783. FILE *yyoutput;
  784. int yytype;
  785. YYSTYPE const * const yyvaluep;
  786. DAPparsestate* parsestate;
  787. #endif
  788. {
  789. if (!yyvaluep)
  790. return;
  791. YYUSE (parsestate);
  792. # ifdef YYPRINT
  793. if (yytype < YYNTOKENS)
  794. YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
  795. # else
  796. YYUSE (yyoutput);
  797. # endif
  798. switch (yytype)
  799. {
  800. default:
  801. break;
  802. }
  803. }
  804. /*--------------------------------.
  805. | Print this symbol on YYOUTPUT. |
  806. `--------------------------------*/
  807. #if (defined __STDC__ || defined __C99__FUNC__ \
  808. || defined __cplusplus || defined _MSC_VER)
  809. static void
  810. yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, DAPparsestate* parsestate)
  811. #else
  812. static void
  813. yy_symbol_print (yyoutput, yytype, yyvaluep, parsestate)
  814. FILE *yyoutput;
  815. int yytype;
  816. YYSTYPE const * const yyvaluep;
  817. DAPparsestate* parsestate;
  818. #endif
  819. {
  820. if (yytype < YYNTOKENS)
  821. YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
  822. else
  823. YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
  824. yy_symbol_value_print (yyoutput, yytype, yyvaluep, parsestate);
  825. YYFPRINTF (yyoutput, ")");
  826. }
  827. /*------------------------------------------------------------------.
  828. | yy_stack_print -- Print the state stack from its BOTTOM up to its |
  829. | TOP (included). |
  830. `------------------------------------------------------------------*/
  831. #if (defined __STDC__ || defined __C99__FUNC__ \
  832. || defined __cplusplus || defined _MSC_VER)
  833. static void
  834. yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
  835. #else
  836. static void
  837. yy_stack_print (yybottom, yytop)
  838. yytype_int16 *yybottom;
  839. yytype_int16 *yytop;
  840. #endif
  841. {
  842. YYFPRINTF (stderr, "Stack now");
  843. for (; yybottom <= yytop; yybottom++)
  844. {
  845. int yybot = *yybottom;
  846. YYFPRINTF (stderr, " %d", yybot);
  847. }
  848. YYFPRINTF (stderr, "\n");
  849. }
  850. # define YY_STACK_PRINT(Bottom, Top) \
  851. do { \
  852. if (yydebug) \
  853. yy_stack_print ((Bottom), (Top)); \
  854. } while (YYID (0))
  855. /*------------------------------------------------.
  856. | Report that the YYRULE is going to be reduced. |
  857. `------------------------------------------------*/
  858. #if (defined __STDC__ || defined __C99__FUNC__ \
  859. || defined __cplusplus || defined _MSC_VER)
  860. static void
  861. yy_reduce_print (YYSTYPE *yyvsp, int yyrule, DAPparsestate* parsestate)
  862. #else
  863. static void
  864. yy_reduce_print (yyvsp, yyrule, parsestate)
  865. YYSTYPE *yyvsp;
  866. int yyrule;
  867. DAPparsestate* parsestate;
  868. #endif
  869. {
  870. int yynrhs = yyr2[yyrule];
  871. int yyi;
  872. unsigned long int yylno = yyrline[yyrule];
  873. YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
  874. yyrule - 1, yylno);
  875. /* The symbols being reduced. */
  876. for (yyi = 0; yyi < yynrhs; yyi++)
  877. {
  878. YYFPRINTF (stderr, " $%d = ", yyi + 1);
  879. yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
  880. &(yyvsp[(yyi + 1) - (yynrhs)])
  881. , parsestate);
  882. YYFPRINTF (stderr, "\n");
  883. }
  884. }
  885. # define YY_REDUCE_PRINT(Rule) \
  886. do { \
  887. if (yydebug) \
  888. yy_reduce_print (yyvsp, Rule, parsestate); \
  889. } while (YYID (0))
  890. /* Nonzero means print parse trace. It is left uninitialized so that
  891. multiple parsers can coexist. */
  892. int yydebug;
  893. #else /* !YYDEBUG */
  894. # define YYDPRINTF(Args)
  895. # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
  896. # define YY_STACK_PRINT(Bottom, Top)
  897. # define YY_REDUCE_PRINT(Rule)
  898. #endif /* !YYDEBUG */
  899. /* YYINITDEPTH -- initial size of the parser's stacks. */
  900. #ifndef YYINITDEPTH
  901. # define YYINITDEPTH 200
  902. #endif
  903. /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
  904. if the built-in stack extension method is used).
  905. Do not make this value too large; the results are undefined if
  906. YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
  907. evaluated with infinite-precision integer arithmetic. */
  908. #ifndef YYMAXDEPTH
  909. # define YYMAXDEPTH 10000
  910. #endif
  911. #if YYERROR_VERBOSE
  912. # ifndef yystrlen
  913. # if defined __GLIBC__ && defined _STRING_H
  914. # define yystrlen strlen
  915. # else
  916. /* Return the length of YYSTR. */
  917. #if (defined __STDC__ || defined __C99__FUNC__ \
  918. || defined __cplusplus || defined _MSC_VER)
  919. static YYSIZE_T
  920. yystrlen (const char *yystr)
  921. #else
  922. static YYSIZE_T
  923. yystrlen (yystr)
  924. const char *yystr;
  925. #endif
  926. {
  927. YYSIZE_T yylen;
  928. for (yylen = 0; yystr[yylen]; yylen++)
  929. continue;
  930. return yylen;
  931. }
  932. # endif
  933. # endif
  934. # ifndef yystpcpy
  935. # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
  936. # define yystpcpy stpcpy
  937. # else
  938. /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
  939. YYDEST. */
  940. #if (defined __STDC__ || defined __C99__FUNC__ \
  941. || defined __cplusplus || defined _MSC_VER)
  942. static char *
  943. yystpcpy (char *yydest, const char *yysrc)
  944. #else
  945. static char *
  946. yystpcpy (yydest, yysrc)
  947. char *yydest;
  948. const char *yysrc;
  949. #endif
  950. {
  951. char *yyd = yydest;
  952. const char *yys = yysrc;
  953. while ((*yyd++ = *yys++) != '\0')
  954. continue;
  955. return yyd - 1;
  956. }
  957. # endif
  958. # endif
  959. # ifndef yytnamerr
  960. /* Copy to YYRES the contents of YYSTR after stripping away unnecessary
  961. quotes and backslashes, so that it's suitable for yyerror. The
  962. heuristic is that double-quoting is unnecessary unless the string
  963. contains an apostrophe, a comma, or backslash (other than
  964. backslash-backslash). YYSTR is taken from yytname. If YYRES is
  965. null, do not copy; instead, return the length of what the result
  966. would have been. */
  967. static YYSIZE_T
  968. yytnamerr (char *yyres, const char *yystr)
  969. {
  970. if (*yystr == '"')
  971. {
  972. YYSIZE_T yyn = 0;
  973. char const *yyp = yystr;
  974. for (;;)
  975. switch (*++yyp)
  976. {
  977. case '\'':
  978. case ',':
  979. goto do_not_strip_quotes;
  980. case '\\':
  981. if (*++yyp != '\\')
  982. goto do_not_strip_quotes;
  983. /* Fall through. */
  984. default:
  985. if (yyres)
  986. yyres[yyn] = *yyp;
  987. yyn++;
  988. break;
  989. case '"':
  990. if (yyres)
  991. yyres[yyn] = '\0';
  992. return yyn;
  993. }
  994. do_not_strip_quotes: ;
  995. }
  996. if (! yyres)
  997. return yystrlen (yystr);
  998. return yystpcpy (yyres, yystr) - yyres;
  999. }
  1000. # endif
  1001. /* Copy into YYRESULT an error message about the unexpected token
  1002. YYCHAR while in state YYSTATE. Return the number of bytes copied,
  1003. including the terminating null byte. If YYRESULT is null, do not
  1004. copy anything; just return the number of bytes that would be
  1005. copied. As a special case, return 0 if an ordinary "syntax error"
  1006. message will do. Return YYSIZE_MAXIMUM if overflow occurs during
  1007. size calculation. */
  1008. static YYSIZE_T
  1009. yysyntax_error (char *yyresult, int yystate, int yychar)
  1010. {
  1011. int yyn = yypact[yystate];
  1012. if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
  1013. return 0;
  1014. else
  1015. {
  1016. int yytype = YYTRANSLATE (yychar);
  1017. YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]);
  1018. YYSIZE_T yysize = yysize0;
  1019. YYSIZE_T yysize1;
  1020. int yysize_overflow = 0;
  1021. enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
  1022. char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
  1023. int yyx;
  1024. # if 0
  1025. /* This is so xgettext sees the translatable formats that are
  1026. constructed on the fly. */
  1027. YY_("syntax error, unexpected %s");
  1028. YY_("syntax error, unexpected %s, expecting %s");
  1029. YY_("syntax error, unexpected %s, expecting %s or %s");
  1030. YY_("syntax error, unexpected %s, expecting %s or %s or %s");
  1031. YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
  1032. # endif
  1033. char *yyfmt;
  1034. char const *yyf;
  1035. static char const yyunexpected[] = "syntax error, unexpected %s";
  1036. static char const yyexpecting[] = ", expecting %s";
  1037. static char const yyor[] = " or %s";
  1038. char yyformat[sizeof yyunexpected
  1039. + sizeof yyexpecting - 1
  1040. + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2)
  1041. * (sizeof yyor - 1))];
  1042. char const *yyprefix = yyexpecting;
  1043. /* Start YYX at -YYN if negative to avoid negative indexes in
  1044. YYCHECK. */
  1045. int yyxbegin = yyn < 0 ? -yyn : 0;
  1046. /* Stay within bounds of both yycheck and yytname. */
  1047. int yychecklim = YYLAST - yyn + 1;
  1048. int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
  1049. int yycount = 1;
  1050. yyarg[0] = yytname[yytype];
  1051. yyfmt = yystpcpy (yyformat, yyunexpected);
  1052. for (yyx = yyxbegin; yyx < yyxend; ++yyx)
  1053. if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
  1054. {
  1055. if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
  1056. {
  1057. yycount = 1;
  1058. yysize = yysize0;
  1059. yyformat[sizeof yyunexpected - 1] = '\0';
  1060. break;
  1061. }
  1062. yyarg[yycount++] = yytname[yyx];
  1063. yysize1 = yysize + yytnamerr (0, yytname[yyx]);
  1064. yysize_overflow |= (yysize1 < yysize);
  1065. yysize = yysize1;
  1066. yyfmt = yystpcpy (yyfmt, yyprefix);
  1067. yyprefix = yyor;
  1068. }
  1069. yyf = YY_(yyformat);
  1070. yysize1 = yysize + yystrlen (yyf);
  1071. yysize_overflow |= (yysize1 < yysize);
  1072. yysize = yysize1;
  1073. if (yysize_overflow)
  1074. return YYSIZE_MAXIMUM;
  1075. if (yyresult)
  1076. {
  1077. /* Avoid sprintf, as that infringes on the user's name space.
  1078. Don't have undefined behavior even if the translation
  1079. produced a string with the wrong number of "%s"s. */
  1080. char *yyp = yyresult;
  1081. int yyi = 0;
  1082. while ((*yyp = *yyf) != '\0')
  1083. {
  1084. if (*yyp == '%' && yyf[1] == 's' && yyi < yycount)
  1085. {
  1086. yyp += yytnamerr (yyp, yyarg[yyi++]);
  1087. yyf += 2;
  1088. }
  1089. else
  1090. {
  1091. yyp++;
  1092. yyf++;
  1093. }
  1094. }
  1095. }
  1096. return yysize;
  1097. }
  1098. }
  1099. #endif /* YYERROR_VERBOSE */
  1100. /*-----------------------------------------------.
  1101. | Release the memory associated to this symbol. |
  1102. `-----------------------------------------------*/
  1103. /*ARGSUSED*/
  1104. #if (defined __STDC__ || defined __C99__FUNC__ \
  1105. || defined __cplusplus || defined _MSC_VER)
  1106. static void
  1107. yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, DAPparsestate* parsestate)
  1108. #else
  1109. static void
  1110. yydestruct (yymsg, yytype, yyvaluep, parsestate)
  1111. const char *yymsg;
  1112. int yytype;
  1113. YYSTYPE *yyvaluep;
  1114. DAPparsestate* parsestate;
  1115. #endif
  1116. {
  1117. YYUSE (yyvaluep);
  1118. YYUSE (parsestate);
  1119. if (!yymsg)
  1120. yymsg = "Deleting";
  1121. YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
  1122. switch (yytype)
  1123. {
  1124. default:
  1125. break;
  1126. }
  1127. }
  1128. /* Prevent warnings from -Wmissing-prototypes. */
  1129. #ifdef YYPARSE_PARAM
  1130. #if defined __STDC__ || defined __cplusplus
  1131. int yyparse (void *YYPARSE_PARAM);
  1132. #else
  1133. int yyparse ();
  1134. #endif
  1135. #else /* ! YYPARSE_PARAM */
  1136. #if defined __STDC__ || defined __cplusplus
  1137. int yyparse (DAPparsestate* parsestate);
  1138. #else
  1139. int yyparse ();
  1140. #endif
  1141. #endif /* ! YYPARSE_PARAM */
  1142. /*-------------------------.
  1143. | yyparse or yypush_parse. |
  1144. `-------------------------*/
  1145. #ifdef YYPARSE_PARAM
  1146. #if (defined __STDC__ || defined __C99__FUNC__ \
  1147. || defined __cplusplus || defined _MSC_VER)
  1148. int
  1149. yyparse (void *YYPARSE_PARAM)
  1150. #else
  1151. int
  1152. yyparse (YYPARSE_PARAM)
  1153. void *YYPARSE_PARAM;
  1154. #endif
  1155. #else /* ! YYPARSE_PARAM */
  1156. #if (defined __STDC__ || defined __C99__FUNC__ \
  1157. || defined __cplusplus || defined _MSC_VER)
  1158. int
  1159. yyparse (DAPparsestate* parsestate)
  1160. #else
  1161. int
  1162. yyparse (parsestate)
  1163. DAPparsestate* parsestate;
  1164. #endif
  1165. #endif
  1166. {
  1167. /* The lookahead symbol. */
  1168. int yychar;
  1169. /* The semantic value of the lookahead symbol. */
  1170. YYSTYPE yylval;
  1171. /* Number of syntax errors so far. */
  1172. int yynerrs;
  1173. int yystate;
  1174. /* Number of tokens to shift before error messages enabled. */
  1175. int yyerrstatus;
  1176. /* The stacks and their tools:
  1177. `yyss': related to states.
  1178. `yyvs': related to semantic values.
  1179. Refer to the stacks thru separate pointers, to allow yyoverflow
  1180. to reallocate them elsewhere. */
  1181. /* The state stack. */
  1182. yytype_int16 yyssa[YYINITDEPTH];
  1183. yytype_int16 *yyss;
  1184. yytype_int16 *yyssp;
  1185. /* The semantic value stack. */
  1186. YYSTYPE yyvsa[YYINITDEPTH];
  1187. YYSTYPE *yyvs;
  1188. YYSTYPE *yyvsp;
  1189. YYSIZE_T yystacksize;
  1190. int yyn;
  1191. int yyresult;
  1192. /* Lookahead token as an internal (translated) token number. */
  1193. int yytoken;
  1194. /* The variables used to return semantic value and location from the
  1195. action routines. */
  1196. YYSTYPE yyval;
  1197. #if YYERROR_VERBOSE
  1198. /* Buffer for error messages, and its allocated size. */
  1199. char yymsgbuf[128];
  1200. char *yymsg = yymsgbuf;
  1201. YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
  1202. #endif
  1203. #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))
  1204. /* The number of symbols on the RHS of the reduced rule.
  1205. Keep to zero when no symbol should be popped. */
  1206. int yylen = 0;
  1207. yytoken = 0;
  1208. yyss = yyssa;
  1209. yyvs = yyvsa;
  1210. yystacksize = YYINITDEPTH;
  1211. YYDPRINTF ((stderr, "Starting parse\n"));
  1212. yystate = 0;
  1213. yyerrstatus = 0;
  1214. yynerrs = 0;
  1215. yychar = YYEMPTY; /* Cause a token to be read. */
  1216. /* Initialize stack pointers.
  1217. Waste one element of value and location stack
  1218. so that they stay on the same level as the state stack.
  1219. The wasted elements are never initialized. */
  1220. yyssp = yyss;
  1221. yyvsp = yyvs;
  1222. goto yysetstate;
  1223. /*------------------------------------------------------------.
  1224. | yynewstate -- Push a new state, which is found in yystate. |
  1225. `------------------------------------------------------------*/
  1226. yynewstate:
  1227. /* In all cases, when you get here, the value and location stacks
  1228. have just been pushed. So pushing a state here evens the stacks. */
  1229. yyssp++;
  1230. yysetstate:
  1231. *yyssp = yystate;
  1232. if (yyss + yystacksize - 1 <= yyssp)
  1233. {
  1234. /* Get the current used size of the three stacks, in elements. */
  1235. YYSIZE_T yysize = yyssp - yyss + 1;
  1236. #ifdef yyoverflow
  1237. {
  1238. /* Give user a chance to reallocate the stack. Use copies of
  1239. these so that the &'s don't force the real ones into
  1240. memory. */
  1241. YYSTYPE *yyvs1 = yyvs;
  1242. yytype_int16 *yyss1 = yyss;
  1243. /* Each stack pointer address is followed by the size of the
  1244. data in use in that stack, in bytes. This used to be a
  1245. conditional around just the two extra args, but that might
  1246. be undefined if yyoverflow is a macro. */
  1247. yyoverflow (YY_("memory exhausted"),
  1248. &yyss1, yysize * sizeof (*yyssp),
  1249. &yyvs1, yysize * sizeof (*yyvsp),
  1250. &yystacksize);
  1251. yyss = yyss1;
  1252. yyvs = yyvs1;
  1253. }
  1254. #else /* no yyoverflow */
  1255. # ifndef YYSTACK_RELOCATE
  1256. goto yyexhaustedlab;
  1257. # else
  1258. /* Extend the stack our own way. */
  1259. if (YYMAXDEPTH <= yystacksize)
  1260. goto yyexhaustedlab;
  1261. yystacksize *= 2;
  1262. if (YYMAXDEPTH < yystacksize)
  1263. yystacksize = YYMAXDEPTH;
  1264. {
  1265. yytype_int16 *yyss1 = yyss;
  1266. union yyalloc *yyptr =
  1267. (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
  1268. if (! yyptr)
  1269. goto yyexhaustedlab;
  1270. YYSTACK_RELOCATE (yyss_alloc, yyss);
  1271. YYSTACK_RELOCATE (yyvs_alloc, yyvs);
  1272. # undef YYSTACK_RELOCATE
  1273. if (yyss1 != yyssa)
  1274. YYSTACK_FREE (yyss1);
  1275. }
  1276. # endif
  1277. #endif /* no yyoverflow */
  1278. yyssp = yyss + yysize - 1;
  1279. yyvsp = yyvs + yysize - 1;
  1280. YYDPRINTF ((stderr, "Stack size increased to %lu\n",
  1281. (unsigned long int) yystacksize));
  1282. if (yyss + yystacksize - 1 <= yyssp)
  1283. YYABORT;
  1284. }
  1285. YYDPRINTF ((stderr, "Entering state %d\n", yystate));
  1286. if (yystate == YYFINAL)
  1287. YYACCEPT;
  1288. goto yybackup;
  1289. /*-----------.
  1290. | yybackup. |
  1291. `-----------*/
  1292. yybackup:
  1293. /* Do appropriate processing given the current state. Read a
  1294. lookahead token if we need one and don't already have one. */
  1295. /* First try to decide what to do without reference to lookahead token. */
  1296. yyn = yypact[yystate];
  1297. if (yyn == YYPACT_NINF)
  1298. goto yydefault;
  1299. /* Not known => get a lookahead token if don't already have one. */
  1300. /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
  1301. if (yychar == YYEMPTY)
  1302. {
  1303. YYDPRINTF ((stderr, "Reading a token: "));
  1304. yychar = YYLEX;
  1305. }
  1306. if (yychar <= YYEOF)
  1307. {
  1308. yychar = yytoken = YYEOF;
  1309. YYDPRINTF ((stderr, "Now at end of input.\n"));
  1310. }
  1311. else
  1312. {
  1313. yytoken = YYTRANSLATE (yychar);
  1314. YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
  1315. }
  1316. /* If the proper action on seeing token YYTOKEN is to reduce or to
  1317. detect an error, take that action. */
  1318. yyn += yytoken;
  1319. if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
  1320. goto yydefault;
  1321. yyn = yytable[yyn];
  1322. if (yyn <= 0)
  1323. {
  1324. if (yyn == 0 || yyn == YYTABLE_NINF)
  1325. goto yyerrlab;
  1326. yyn = -yyn;
  1327. goto yyreduce;
  1328. }
  1329. /* Count tokens shifted since error; after three, turn off error
  1330. status. */
  1331. if (yyerrstatus)
  1332. yyerrstatus--;
  1333. /* Shift the lookahead token. */
  1334. YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
  1335. /* Discard the shifted token. */
  1336. yychar = YYEMPTY;
  1337. yystate = yyn;
  1338. *++yyvsp = yylval;
  1339. goto yynewstate;
  1340. /*-----------------------------------------------------------.
  1341. | yydefault -- do the default action for the current state. |
  1342. `-----------------------------------------------------------*/
  1343. yydefault:
  1344. yyn = yydefact[yystate];
  1345. if (yyn == 0)
  1346. goto yyerrlab;
  1347. goto yyreduce;
  1348. /*-----------------------------.
  1349. | yyreduce -- Do a reduction. |
  1350. `-----------------------------*/
  1351. yyreduce:
  1352. /* yyn is the number of a rule to reduce with. */
  1353. yylen = yyr2[yyn];
  1354. /* If YYLEN is nonzero, implement the default value of the action:
  1355. `$$ = $1'.
  1356. Otherwise, the following line sets YYVAL to garbage.
  1357. This behavior is undocumented and Bison
  1358. users should not rely upon it. Assigning to YYVAL
  1359. unconditionally makes the parser a bit smaller, and it avoids a
  1360. GCC warning that YYVAL may be used uninitialized. */
  1361. yyval = yyvsp[1-yylen];
  1362. YY_REDUCE_PRINT (yyn);
  1363. switch (yyn)
  1364. {
  1365. case 6:
  1366. /* Line 1464 of yacc.c */
  1367. #line 57 "dap.y"
  1368. {dap_unrecognizedresponse(parsestate); YYABORT;;}
  1369. break;
  1370. case 7:
  1371. /* Line 1464 of yacc.c */
  1372. #line 62 "dap.y"
  1373. {dap_tagparse(parsestate,SCAN_DATASET);;}
  1374. break;
  1375. case 8:
  1376. /* Line 1464 of yacc.c */
  1377. #line 66 "dap.y"
  1378. {dap_tagparse(parsestate,SCAN_ATTR);;}
  1379. break;
  1380. case 9:
  1381. /* Line 1464 of yacc.c */
  1382. #line 70 "dap.y"
  1383. {dap_tagparse(parsestate,SCAN_ERROR);;}
  1384. break;
  1385. case 10:
  1386. /* Line 1464 of yacc.c */
  1387. #line 75 "dap.y"
  1388. {dap_datasetbody(parsestate,(yyvsp[(4) - (5)]),(yyvsp[(2) - (5)]));;}
  1389. break;
  1390. case 11:
  1391. /* Line 1464 of yacc.c */
  1392. #line 80 "dap.y"
  1393. {(yyval)=dap_declarations(parsestate,null,null);;}
  1394. break;
  1395. case 12:
  1396. /* Line 1464 of yacc.c */
  1397. #line 81 "dap.y"
  1398. {(yyval)=dap_declarations(parsestate,(yyvsp[(1) - (2)]),(yyvsp[(2) - (2)]));;}
  1399. break;
  1400. case 13:
  1401. /* Line 1464 of yacc.c */
  1402. #line 88 "dap.y"
  1403. {(yyval)=dap_makebase(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(1) - (4)]),(yyvsp[(3) - (4)]));;}
  1404. break;
  1405. case 14:
  1406. /* Line 1464 of yacc.c */
  1407. #line 90 "dap.y"
  1408. {if(((yyval)=dap_makestructure(parsestate,(yyvsp[(5) - (7)]),(yyvsp[(6) - (7)]),(yyvsp[(3) - (7)])))==null) {YYABORT;};}
  1409. break;
  1410. case 15:
  1411. /* Line 1464 of yacc.c */
  1412. #line 92 "dap.y"
  1413. {if(((yyval)=dap_makesequence(parsestate,(yyvsp[(5) - (6)]),(yyvsp[(3) - (6)])))==null) {YYABORT;};}
  1414. break;
  1415. case 16:
  1416. /* Line 1464 of yacc.c */
  1417. #line 95 "dap.y"
  1418. {if(((yyval)=dap_makegrid(parsestate,(yyvsp[(10) - (11)]),(yyvsp[(5) - (11)]),(yyvsp[(8) - (11)])))==null) {YYABORT;};}
  1419. break;
  1420. case 17:
  1421. /* Line 1464 of yacc.c */
  1422. #line 97 "dap.y"
  1423. {daperror(parsestate,"Unrecognized type"); YYABORT;;}
  1424. break;
  1425. case 18:
  1426. /* Line 1464 of yacc.c */
  1427. #line 102 "dap.y"
  1428. {(yyval)=(Object)SCAN_BYTE;;}
  1429. break;
  1430. case 19:
  1431. /* Line 1464 of yacc.c */
  1432. #line 103 "dap.y"
  1433. {(yyval)=(Object)SCAN_INT16;;}
  1434. break;
  1435. case 20:
  1436. /* Line 1464 of yacc.c */
  1437. #line 104 "dap.y"
  1438. {(yyval)=(Object)SCAN_UINT16;;}
  1439. break;
  1440. case 21:
  1441. /* Line 1464 of yacc.c */
  1442. #line 105 "dap.y"
  1443. {(yyval)=(Object)SCAN_INT32;;}
  1444. break;
  1445. case 22:
  1446. /* Line 1464 of yacc.c */
  1447. #line 106 "dap.y"
  1448. {(yyval)=(Object)SCAN_UINT32;;}
  1449. break;
  1450. case 23:
  1451. /* Line 1464 of yacc.c */
  1452. #line 107 "dap.y"
  1453. {(yyval)=(Object)SCAN_FLOAT32;;}
  1454. break;
  1455. case 24:
  1456. /* Line 1464 of yacc.c */
  1457. #line 108 "dap.y"
  1458. {(yyval)=(Object)SCAN_FLOAT64;;}
  1459. break;
  1460. case 25:
  1461. /* Line 1464 of yacc.c */
  1462. #line 109 "dap.y"
  1463. {(yyval)=(Object)SCAN_URL;;}
  1464. break;
  1465. case 26:
  1466. /* Line 1464 of yacc.c */
  1467. #line 110 "dap.y"
  1468. {(yyval)=(Object)SCAN_STRING;;}
  1469. break;
  1470. case 27:
  1471. /* Line 1464 of yacc.c */
  1472. #line 114 "dap.y"
  1473. {(yyval)=dap_arraydecls(parsestate,null,null);;}
  1474. break;
  1475. case 28:
  1476. /* Line 1464 of yacc.c */
  1477. #line 115 "dap.y"
  1478. {(yyval)=dap_arraydecls(parsestate,(yyvsp[(1) - (2)]),(yyvsp[(2) - (2)]));;}
  1479. break;
  1480. case 29:
  1481. /* Line 1464 of yacc.c */
  1482. #line 119 "dap.y"
  1483. {(yyval)=dap_arraydecl(parsestate,null,(yyvsp[(2) - (3)]));;}
  1484. break;
  1485. case 30:
  1486. /* Line 1464 of yacc.c */
  1487. #line 120 "dap.y"
  1488. {(yyval)=dap_arraydecl(parsestate,null,(yyvsp[(3) - (4)]));;}
  1489. break;
  1490. case 31:
  1491. /* Line 1464 of yacc.c */
  1492. #line 121 "dap.y"
  1493. {(yyval)=dap_arraydecl(parsestate,(yyvsp[(2) - (5)]),(yyvsp[(4) - (5)]));;}
  1494. break;
  1495. case 32:
  1496. /* Line 1464 of yacc.c */
  1497. #line 123 "dap.y"
  1498. {daperror(parsestate,"Illegal dimension declaration"); YYABORT;;}
  1499. break;
  1500. case 33:
  1501. /* Line 1464 of yacc.c */
  1502. #line 127 "dap.y"
  1503. {(yyval)=(yyvsp[(1) - (1)]);;}
  1504. break;
  1505. case 34:
  1506. /* Line 1464 of yacc.c */
  1507. #line 129 "dap.y"
  1508. {daperror(parsestate,"Illegal dataset declaration"); YYABORT;;}
  1509. break;
  1510. case 35:
  1511. /* Line 1464 of yacc.c */
  1512. #line 132 "dap.y"
  1513. {(yyval)=(yyvsp[(1) - (1)]);;}
  1514. break;
  1515. case 36:
  1516. /* Line 1464 of yacc.c */
  1517. #line 135 "dap.y"
  1518. {dap_attributebody(parsestate,(yyvsp[(2) - (3)]));;}
  1519. break;
  1520. case 37:
  1521. /* Line 1464 of yacc.c */
  1522. #line 137 "dap.y"
  1523. {daperror(parsestate,"Illegal DAS body"); YYABORT;;}
  1524. break;
  1525. case 38:
  1526. /* Line 1464 of yacc.c */
  1527. #line 141 "dap.y"
  1528. {(yyval)=dap_attrlist(parsestate,null,null);;}
  1529. break;
  1530. case 39:
  1531. /* Line 1464 of yacc.c */
  1532. #line 142 "dap.y"
  1533. {(yyval)=dap_attrlist(parsestate,(yyvsp[(1) - (2)]),(yyvsp[(2) - (2)]));;}
  1534. break;
  1535. case 40:
  1536. /* Line 1464 of yacc.c */
  1537. #line 146 "dap.y"
  1538. {(yyval)=null;;}
  1539. break;
  1540. case 41:
  1541. /* Line 1464 of yacc.c */
  1542. #line 148 "dap.y"
  1543. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_BYTE);;}
  1544. break;
  1545. case 42:
  1546. /* Line 1464 of yacc.c */
  1547. #line 150 "dap.y"
  1548. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_INT16);;}
  1549. break;
  1550. case 43:
  1551. /* Line 1464 of yacc.c */
  1552. #line 152 "dap.y"
  1553. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_UINT16);;}
  1554. break;
  1555. case 44:
  1556. /* Line 1464 of yacc.c */
  1557. #line 154 "dap.y"
  1558. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_INT32);;}
  1559. break;
  1560. case 45:
  1561. /* Line 1464 of yacc.c */
  1562. #line 156 "dap.y"
  1563. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_UINT32);;}
  1564. break;
  1565. case 46:
  1566. /* Line 1464 of yacc.c */
  1567. #line 158 "dap.y"
  1568. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_FLOAT32);;}
  1569. break;
  1570. case 47:
  1571. /* Line 1464 of yacc.c */
  1572. #line 160 "dap.y"
  1573. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_FLOAT64);;}
  1574. break;
  1575. case 48:
  1576. /* Line 1464 of yacc.c */
  1577. #line 162 "dap.y"
  1578. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_STRING);;}
  1579. break;
  1580. case 49:
  1581. /* Line 1464 of yacc.c */
  1582. #line 164 "dap.y"
  1583. {(yyval)=dap_attribute(parsestate,(yyvsp[(2) - (4)]),(yyvsp[(3) - (4)]),(Object)SCAN_URL);;}
  1584. break;
  1585. case 50:
  1586. /* Line 1464 of yacc.c */
  1587. #line 165 "dap.y"
  1588. {(yyval)=dap_attrset(parsestate,(yyvsp[(1) - (4)]),(yyvsp[(3) - (4)]));;}
  1589. break;
  1590. case 51:
  1591. /* Line 1464 of yacc.c */
  1592. #line 167 "dap.y"
  1593. {daperror(parsestate,"Illegal attribute"); YYABORT;;}
  1594. break;
  1595. case 52:
  1596. /* Line 1464 of yacc.c */
  1597. #line 171 "dap.y"
  1598. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_BYTE);;}
  1599. break;
  1600. case 53:
  1601. /* Line 1464 of yacc.c */
  1602. #line 173 "dap.y"
  1603. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_BYTE);;}
  1604. break;
  1605. case 54:
  1606. /* Line 1464 of yacc.c */
  1607. #line 176 "dap.y"
  1608. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_INT16);;}
  1609. break;
  1610. case 55:
  1611. /* Line 1464 of yacc.c */
  1612. #line 178 "dap.y"
  1613. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_INT16);;}
  1614. break;
  1615. case 56:
  1616. /* Line 1464 of yacc.c */
  1617. #line 181 "dap.y"
  1618. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_UINT16);;}
  1619. break;
  1620. case 57:
  1621. /* Line 1464 of yacc.c */
  1622. #line 183 "dap.y"
  1623. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_UINT16);;}
  1624. break;
  1625. case 58:
  1626. /* Line 1464 of yacc.c */
  1627. #line 186 "dap.y"
  1628. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_INT32);;}
  1629. break;
  1630. case 59:
  1631. /* Line 1464 of yacc.c */
  1632. #line 188 "dap.y"
  1633. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_INT32);;}
  1634. break;
  1635. case 60:
  1636. /* Line 1464 of yacc.c */
  1637. #line 191 "dap.y"
  1638. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_UINT32);;}
  1639. break;
  1640. case 61:
  1641. /* Line 1464 of yacc.c */
  1642. #line 192 "dap.y"
  1643. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_UINT32);;}
  1644. break;
  1645. case 62:
  1646. /* Line 1464 of yacc.c */
  1647. #line 195 "dap.y"
  1648. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_FLOAT32);;}
  1649. break;
  1650. case 63:
  1651. /* Line 1464 of yacc.c */
  1652. #line 196 "dap.y"
  1653. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_FLOAT32);;}
  1654. break;
  1655. case 64:
  1656. /* Line 1464 of yacc.c */
  1657. #line 199 "dap.y"
  1658. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_FLOAT64);;}
  1659. break;
  1660. case 65:
  1661. /* Line 1464 of yacc.c */
  1662. #line 200 "dap.y"
  1663. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_FLOAT64);;}
  1664. break;
  1665. case 66:
  1666. /* Line 1464 of yacc.c */
  1667. #line 203 "dap.y"
  1668. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_STRING);;}
  1669. break;
  1670. case 67:
  1671. /* Line 1464 of yacc.c */
  1672. #line 204 "dap.y"
  1673. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_STRING);;}
  1674. break;
  1675. case 68:
  1676. /* Line 1464 of yacc.c */
  1677. #line 208 "dap.y"
  1678. {(yyval)=dap_attrvalue(parsestate,null,(yyvsp[(1) - (1)]),(Object)SCAN_URL);;}
  1679. break;
  1680. case 69:
  1681. /* Line 1464 of yacc.c */
  1682. #line 209 "dap.y"
  1683. {(yyval)=dap_attrvalue(parsestate,(yyvsp[(1) - (3)]),(yyvsp[(3) - (3)]),(Object)SCAN_URL);;}
  1684. break;
  1685. case 70:
  1686. /* Line 1464 of yacc.c */
  1687. #line 213 "dap.y"
  1688. {(yyval)=(yyvsp[(1) - (1)]);;}
  1689. break;
  1690. case 71:
  1691. /* Line 1464 of yacc.c */
  1692. #line 217 "dap.y"
  1693. {(yyval)=(yyvsp[(1) - (1)]);;}
  1694. break;
  1695. case 72:
  1696. /* Line 1464 of yacc.c */
  1697. #line 218 "dap.y"
  1698. {(yyval)=(yyvsp[(1) - (1)]);;}
  1699. break;
  1700. case 73:
  1701. /* Line 1464 of yacc.c */
  1702. #line 229 "dap.y"
  1703. {(yyval)=(yyvsp[(2) - (3)]); (yyval)=(yyvsp[(3) - (3)]); (yyval)=null;;}
  1704. break;
  1705. case 74:
  1706. /* Line 1464 of yacc.c */
  1707. #line 234 "dap.y"
  1708. {dap_errorbody(parsestate,(yyvsp[(2) - (7)]),(yyvsp[(3) - (7)]),(yyvsp[(4) - (7)]),(yyvsp[(5) - (7)]));;}
  1709. break;
  1710. case 75:
  1711. /* Line 1464 of yacc.c */
  1712. #line 237 "dap.y"
  1713. {(yyval)=null;;}
  1714. break;
  1715. case 76:
  1716. /* Line 1464 of yacc.c */
  1717. #line 237 "dap.y"
  1718. {(yyval)=(yyvsp[(3) - (4)]);;}
  1719. break;
  1720. case 77:
  1721. /* Line 1464 of yacc.c */
  1722. #line 238 "dap.y"
  1723. {(yyval)=null;;}
  1724. break;
  1725. case 78:
  1726. /* Line 1464 of yacc.c */
  1727. #line 238 "dap.y"
  1728. {(yyval)=(yyvsp[(3) - (4)]);;}
  1729. break;
  1730. case 79:
  1731. /* Line 1464 of yacc.c */
  1732. #line 239 "dap.y"
  1733. {(yyval)=null;;}
  1734. break;
  1735. case 80:
  1736. /* Line 1464 of yacc.c */
  1737. #line 239 "dap.y"
  1738. {(yyval)=(yyvsp[(3) - (4)]);;}
  1739. break;
  1740. case 81:
  1741. /* Line 1464 of yacc.c */
  1742. #line 240 "dap.y"
  1743. {(yyval)=null;;}
  1744. break;
  1745. case 82:
  1746. /* Line 1464 of yacc.c */
  1747. #line 240 "dap.y"
  1748. {(yyval)=(yyvsp[(3) - (4)]);;}
  1749. break;
  1750. case 83:
  1751. /* Line 1464 of yacc.c */
  1752. #line 246 "dap.y"
  1753. {(yyval)=dapdecode(parsestate->lexstate,(yyvsp[(1) - (1)]));;}
  1754. break;
  1755. case 84:
  1756. /* Line 1464 of yacc.c */
  1757. #line 247 "dap.y"
  1758. {(yyval)=strdup("alias");;}
  1759. break;
  1760. case 85:
  1761. /* Line 1464 of yacc.c */
  1762. #line 248 "dap.y"
  1763. {(yyval)=strdup("array");;}
  1764. break;
  1765. case 86:
  1766. /* Line 1464 of yacc.c */
  1767. #line 249 "dap.y"
  1768. {(yyval)=strdup("attributes");;}
  1769. break;
  1770. case 87:
  1771. /* Line 1464 of yacc.c */
  1772. #line 250 "dap.y"
  1773. {(yyval)=strdup("byte");;}
  1774. break;
  1775. case 88:
  1776. /* Line 1464 of yacc.c */
  1777. #line 251 "dap.y"
  1778. {(yyval)=strdup("dataset");;}
  1779. break;
  1780. case 89:
  1781. /* Line 1464 of yacc.c */
  1782. #line 252 "dap.y"
  1783. {(yyval)=strdup("data");;}
  1784. break;
  1785. case 90:
  1786. /* Line 1464 of yacc.c */
  1787. #line 253 "dap.y"
  1788. {(yyval)=strdup("error");;}
  1789. break;
  1790. case 91:
  1791. /* Line 1464 of yacc.c */
  1792. #line 254 "dap.y"
  1793. {(yyval)=strdup("float32");;}
  1794. break;
  1795. case 92:
  1796. /* Line 1464 of yacc.c */
  1797. #line 255 "dap.y"
  1798. {(yyval)=strdup("float64");;}
  1799. break;
  1800. case 93:
  1801. /* Line 1464 of yacc.c */
  1802. #line 256 "dap.y"
  1803. {(yyval)=strdup("grid");;}
  1804. break;
  1805. case 94:
  1806. /* Line 1464 of yacc.c */
  1807. #line 257 "dap.y"
  1808. {(yyval)=strdup("int16");;}
  1809. break;
  1810. case 95:
  1811. /* Line 1464 of yacc.c */
  1812. #line 258 "dap.y"
  1813. {(yyval)=strdup("int32");;}
  1814. break;
  1815. case 96:
  1816. /* Line 1464 of yacc.c */
  1817. #line 259 "dap.y"
  1818. {(yyval)=strdup("maps");;}
  1819. break;
  1820. case 97:
  1821. /* Line 1464 of yacc.c */
  1822. #line 260 "dap.y"
  1823. {(yyval)=strdup("sequence");;}
  1824. break;
  1825. case 98:
  1826. /* Line 1464 of yacc.c */
  1827. #line 261 "dap.y"
  1828. {(yyval)=strdup("string");;}
  1829. break;
  1830. case 99:
  1831. /* Line 1464 of yacc.c */
  1832. #line 262 "dap.y"
  1833. {(yyval)=strdup("structure");;}
  1834. break;
  1835. case 100:
  1836. /* Line 1464 of yacc.c */
  1837. #line 263 "dap.y"
  1838. {(yyval)=strdup("uint16");;}
  1839. break;
  1840. case 101:
  1841. /* Line 1464 of yacc.c */
  1842. #line 264 "dap.y"
  1843. {(yyval)=strdup("uint32");;}
  1844. break;
  1845. case 102:
  1846. /* Line 1464 of yacc.c */
  1847. #line 265 "dap.y"
  1848. {(yyval)=strdup("url");;}
  1849. break;
  1850. case 103:
  1851. /* Line 1464 of yacc.c */
  1852. #line 266 "dap.y"
  1853. {(yyval)=strdup("code");;}
  1854. break;
  1855. case 104:
  1856. /* Line 1464 of yacc.c */
  1857. #line 267 "dap.y"
  1858. {(yyval)=strdup("message");;}
  1859. break;
  1860. case 105:
  1861. /* Line 1464 of yacc.c */
  1862. #line 268 "dap.y"
  1863. {(yyval)=strdup("program");;}
  1864. break;
  1865. case 106:
  1866. /* Line 1464 of yacc.c */
  1867. #line 269 "dap.y"
  1868. {(yyval)=strdup("program_type");;}
  1869. break;
  1870. /* Line 1464 of yacc.c */
  1871. #line 2280 "dap.tab.c"
  1872. default: break;
  1873. }
  1874. YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
  1875. YYPOPSTACK (yylen);
  1876. yylen = 0;
  1877. YY_STACK_PRINT (yyss, yyssp);
  1878. *++yyvsp = yyval;
  1879. /* Now `shift' the result of the reduction. Determine what state
  1880. that goes to, based on the state we popped back to and the rule
  1881. number reduced by. */
  1882. yyn = yyr1[yyn];
  1883. yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
  1884. if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
  1885. yystate = yytable[yystate];
  1886. else
  1887. yystate = yydefgoto[yyn - YYNTOKENS];
  1888. goto yynewstate;
  1889. /*------------------------------------.
  1890. | yyerrlab -- here on detecting error |
  1891. `------------------------------------*/
  1892. yyerrlab:
  1893. /* If not already recovering from an error, report this error. */
  1894. if (!yyerrstatus)
  1895. {
  1896. ++yynerrs;
  1897. #if ! YYERROR_VERBOSE
  1898. yyerror (parsestate, YY_("syntax error"));
  1899. #else
  1900. {
  1901. YYSIZE_T yysize = yysyntax_error (0, yystate, yychar);
  1902. if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM)
  1903. {
  1904. YYSIZE_T yyalloc = 2 * yysize;
  1905. if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM))
  1906. yyalloc = YYSTACK_ALLOC_MAXIMUM;
  1907. if (yymsg != yymsgbuf)
  1908. YYSTACK_FREE (yymsg);
  1909. yymsg = (char *) YYSTACK_ALLOC (yyalloc);
  1910. if (yymsg)
  1911. yymsg_alloc = yyalloc;
  1912. else
  1913. {
  1914. yymsg = yymsgbuf;
  1915. yymsg_alloc = sizeof yymsgbuf;
  1916. }
  1917. }
  1918. if (0 < yysize && yysize <= yymsg_alloc)
  1919. {
  1920. (void) yysyntax_error (yymsg, yystate, yychar);
  1921. yyerror (parsestate, yymsg);
  1922. }
  1923. else
  1924. {
  1925. yyerror (parsestate, YY_("syntax error"));
  1926. if (yysize != 0)
  1927. goto yyexhaustedlab;
  1928. }
  1929. }
  1930. #endif
  1931. }
  1932. if (yyerrstatus == 3)
  1933. {
  1934. /* If just tried and failed to reuse lookahead token after an
  1935. error, discard it. */
  1936. if (yychar <= YYEOF)
  1937. {
  1938. /* Return failure if at end of input. */
  1939. if (yychar == YYEOF)
  1940. YYABORT;
  1941. }
  1942. else
  1943. {
  1944. yydestruct ("Error: discarding",
  1945. yytoken, &yylval, parsestate);
  1946. yychar = YYEMPTY;
  1947. }
  1948. }
  1949. /* Else will try to reuse lookahead token after shifting the error
  1950. token. */
  1951. goto yyerrlab1;
  1952. /*---------------------------------------------------.
  1953. | yyerrorlab -- error raised explicitly by YYERROR. |
  1954. `---------------------------------------------------*/
  1955. yyerrorlab:
  1956. /* Pacify compilers like GCC when the user code never invokes
  1957. YYERROR and the label yyerrorlab therefore never appears in user
  1958. code. */
  1959. if (/*CONSTCOND*/ 0)
  1960. goto yyerrorlab;
  1961. /* Do not reclaim the symbols of the rule which action triggered
  1962. this YYERROR. */
  1963. YYPOPSTACK (yylen);
  1964. yylen = 0;
  1965. YY_STACK_PRINT (yyss, yyssp);
  1966. yystate = *yyssp;
  1967. goto yyerrlab1;
  1968. /*-------------------------------------------------------------.
  1969. | yyerrlab1 -- common code for both syntax error and YYERROR. |
  1970. `-------------------------------------------------------------*/
  1971. yyerrlab1:
  1972. yyerrstatus = 3; /* Each real token shifted decrements this. */
  1973. for (;;)
  1974. {
  1975. yyn = yypact[yystate];
  1976. if (yyn != YYPACT_NINF)
  1977. {
  1978. yyn += YYTERROR;
  1979. if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
  1980. {
  1981. yyn = yytable[yyn];
  1982. if (0 < yyn)
  1983. break;
  1984. }
  1985. }
  1986. /* Pop the current state because it cannot handle the error token. */
  1987. if (yyssp == yyss)
  1988. YYABORT;
  1989. yydestruct ("Error: popping",
  1990. yystos[yystate], yyvsp, parsestate);
  1991. YYPOPSTACK (1);
  1992. yystate = *yyssp;
  1993. YY_STACK_PRINT (yyss, yyssp);
  1994. }
  1995. *++yyvsp = yylval;
  1996. /* Shift the error token. */
  1997. YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
  1998. yystate = yyn;
  1999. goto yynewstate;
  2000. /*-------------------------------------.
  2001. | yyacceptlab -- YYACCEPT comes here. |
  2002. `-------------------------------------*/
  2003. yyacceptlab:
  2004. yyresult = 0;
  2005. goto yyreturn;
  2006. /*-----------------------------------.
  2007. | yyabortlab -- YYABORT comes here. |
  2008. `-----------------------------------*/
  2009. yyabortlab:
  2010. yyresult = 1;
  2011. goto yyreturn;
  2012. #if !defined(yyoverflow) || YYERROR_VERBOSE
  2013. /*-------------------------------------------------.
  2014. | yyexhaustedlab -- memory exhaustion comes here. |
  2015. `-------------------------------------------------*/
  2016. yyexhaustedlab:
  2017. yyerror (parsestate, YY_("memory exhausted"));
  2018. yyresult = 2;
  2019. /* Fall through. */
  2020. #endif
  2021. yyreturn:
  2022. if (yychar != YYEMPTY)
  2023. yydestruct ("Cleanup: discarding lookahead",
  2024. yytoken, &yylval, parsestate);
  2025. /* Do not reclaim the symbols of the rule which action triggered
  2026. this YYABORT or YYACCEPT. */
  2027. YYPOPSTACK (yylen);
  2028. YY_STACK_PRINT (yyss, yyssp);
  2029. while (yyssp != yyss)
  2030. {
  2031. yydestruct ("Cleanup: popping",
  2032. yystos[*yyssp], yyvsp, parsestate);
  2033. YYPOPSTACK (1);
  2034. }
  2035. #ifndef yyoverflow
  2036. if (yyss != yyssa)
  2037. YYSTACK_FREE (yyss);
  2038. #endif
  2039. #if YYERROR_VERBOSE
  2040. if (yymsg != yymsgbuf)
  2041. YYSTACK_FREE (yymsg);
  2042. #endif
  2043. /* Make sure YYID is used. */
  2044. return YYID (yyresult);
  2045. }
  2046. /* Line 1684 of yacc.c */
  2047. #line 272 "dap.y"