dphlparser.c 69 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476
  1. /* A Bison parser, made by GNU Bison 3.7.5. */
  2. /* Bison implementation for Yacc-like parsers in C
  3. Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 Free Software Foundation,
  4. 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. /* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual,
  29. especially those whose name start with YY_ or yy_. They are
  30. private implementation details that can be changed or removed. */
  31. /* All symbols defined below should begin with yy or YY, to avoid
  32. infringing on user name space. This should be done even for local
  33. variables, as they might otherwise be expanded by user macros.
  34. There are some unavoidable exceptions within include files to
  35. define necessary library symbols; they are noted "INFRINGES ON
  36. USER NAME SPACE" below. */
  37. /* Identify Bison output, and Bison version. */
  38. #define YYBISON 30705
  39. /* Bison version string. */
  40. #define YYBISON_VERSION "3.7.5"
  41. /* Skeleton name. */
  42. #define YYSKELETON_NAME "yacc.c"
  43. /* Pure parsers. */
  44. #define YYPURE 0
  45. /* Push parsers. */
  46. #define YYPUSH 0
  47. /* Pull parsers. */
  48. #define YYPULL 1
  49. /* Substitute the type names. */
  50. #define YYSTYPE HLYSTYPE
  51. /* Substitute the variable and function names. */
  52. #define yyparse hlyparse
  53. #define yylex hlylex
  54. #define yyerror hlyerror
  55. #define yydebug hlydebug
  56. #define yynerrs hlynerrs
  57. #define yylval hlylval
  58. #define yychar hlychar
  59. /* First part of user prologue. */
  60. #line 82 "dphl.y"
  61. #include "config.h"
  62. #include <stdio.h>
  63. #include <stdlib.h>
  64. #include <string.h>
  65. #include "splay-tree.h"
  66. #include "main.h"
  67. #include "dp.h"
  68. #include "dphl.h"
  69. #include "dpmem.h"
  70. /* make sure extra debug code is available */
  71. #define YYDEBUG 1
  72. /*
  73. * When Using Bison-2.5.1
  74. * The variable error controls the verbosity of error messages. The
  75. * use of the %error-verbose directive is deprecated in favor of
  76. * %define parse.error "verbose".
  77. */
  78. #define YYERROR_VERBOSE 1
  79. /* memory usage wrapping feature
  80. #ifndef YYFREE
  81. # define YYFREE free
  82. #endif
  83. #ifndef YYMALLOC
  84. # define YYMALLOC malloc
  85. #endif
  86. #ifndef YYREALLOC
  87. # define YYREALLOC realloc
  88. #endif
  89. */
  90. /* in lexer */
  91. extern int hllineno;
  92. extern char *hltext;
  93. extern int html_lex(void);
  94. /*
  95. * In GLR generated parser is:
  96. * YYLEX -- calling `yylex' with the right arguments.
  97. * #define YYLEX yylex (&yylval, &yylloc, pc)
  98. * YYSTYPE *lvalp, YYLTYPE *llocp, struct parser_control *pc
  99. */
  100. static int hlylex(void)
  101. {
  102. int tokencode = 0;
  103. tokencode = html_lex();
  104. if (tokencode == 0) {
  105. tokencode = EOF;
  106. }
  107. /* */
  108. return (tokencode);
  109. }
  110. static void yyerror(const char *msg)
  111. {
  112. if (strlen(dp_errmsg) == 0) {
  113. snprintf(dp_errmsg, 256 - 1, "html %s(): %s at line %d yytext is %s'\n", __func__, msg, hllineno, hltext);
  114. }
  115. printf("html %s(): %s at line %d yytext is `%s'\n", __func__, msg, hllineno, hltext);
  116. fflush(stdout);
  117. fflush(stderr);
  118. return;
  119. }
  120. #line 156 "dphlparser.c"
  121. #ifndef YY_CAST
  122. #ifdef __cplusplus
  123. #define YY_CAST(Type, Val) static_cast<Type> (Val)
  124. #define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast<Type> (Val)
  125. #else
  126. #define YY_CAST(Type, Val) ((Type) (Val))
  127. #define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val))
  128. #endif
  129. #endif
  130. #ifndef YY_NULLPTR
  131. #if defined __cplusplus
  132. #if 201103L <= __cplusplus
  133. #define YY_NULLPTR nullptr
  134. #else
  135. #define YY_NULLPTR 0
  136. #endif
  137. #else
  138. #define YY_NULLPTR ((void*)0)
  139. #endif
  140. #endif
  141. #include "dphlparser.h"
  142. /* Symbol kind. */
  143. enum yysymbol_kind_t {
  144. YYSYMBOL_YYEMPTY = -2,
  145. YYSYMBOL_YYEOF = 0, /* "end of file" */
  146. YYSYMBOL_YYerror = 1, /* error */
  147. YYSYMBOL_YYUNDEF = 2, /* "invalid token" */
  148. YYSYMBOL_HL_DATA = 3, /* "stringdata" */
  149. YYSYMBOL_HL_HTML = 4, /* "<html" */
  150. YYSYMBOL_HL_C_HTML = 5, /* "</html" */
  151. YYSYMBOL_HL_B = 6, /* "<b" */
  152. YYSYMBOL_HL_C_B = 7, /* "</b" */
  153. YYSYMBOL_HL_BR = 8, /* "<br" */
  154. YYSYMBOL_HL_C_BR = 9, /* "</br" */
  155. YYSYMBOL_HL_FONT = 10, /* "<font" */
  156. YYSYMBOL_HL_C_FONT = 11, /* "</font" */
  157. YYSYMBOL_HL_HR = 12, /* "<hr" */
  158. YYSYMBOL_HL_C_HR = 13, /* "</hr" */
  159. YYSYMBOL_HL_I = 14, /* "<i" */
  160. YYSYMBOL_HL_C_I = 15, /* "</i" */
  161. YYSYMBOL_HL_IMG = 16, /* "<img" */
  162. YYSYMBOL_HL_C_IMG = 17, /* "</img" */
  163. YYSYMBOL_HL_O = 18, /* "<o" */
  164. YYSYMBOL_HL_C_O = 19, /* "</o" */
  165. YYSYMBOL_HL_S = 20, /* "<s" */
  166. YYSYMBOL_HL_C_S = 21, /* "</s" */
  167. YYSYMBOL_HL_SUB = 22, /* "<sub" */
  168. YYSYMBOL_HL_C_SUB = 23, /* "</sub" */
  169. YYSYMBOL_HL_SUP = 24, /* "<sup" */
  170. YYSYMBOL_HL_C_SUP = 25, /* "</sup" */
  171. YYSYMBOL_HL_TABLE = 26, /* "<table" */
  172. YYSYMBOL_HL_C_TABLE = 27, /* "</table" */
  173. YYSYMBOL_HL_TD = 28, /* "<td" */
  174. YYSYMBOL_HL_C_TD = 29, /* "</td" */
  175. YYSYMBOL_HL_TR = 30, /* "<tr" */
  176. YYSYMBOL_HL_C_TR = 31, /* "</tr" */
  177. YYSYMBOL_HL_U = 32, /* "<u" */
  178. YYSYMBOL_HL_C_U = 33, /* "</u" */
  179. YYSYMBOL_HL_VR = 34, /* "<vr" */
  180. YYSYMBOL_HL_C_VR = 35, /* "</vr" */
  181. YYSYMBOL_HL_SC = 36, /* "/>" */
  182. YYSYMBOL_HL_C = 37, /* ">" */
  183. YYSYMBOL_HL_IS = 38, /* "=" */
  184. YYSYMBOL_HL_QSTR = 39, /* "string" */
  185. YYSYMBOL_HL_STR = 40, /* "text" */
  186. YYSYMBOL_HL_ALIGN = 41, /* "align" */
  187. YYSYMBOL_HL_BALIGN = 42, /* "balign" */
  188. YYSYMBOL_HL_BGCOLOR = 43, /* "bgcolor" */
  189. YYSYMBOL_HL_BORDER = 44, /* "border" */
  190. YYSYMBOL_HL_CELLBORDER = 45, /* "cellborder" */
  191. YYSYMBOL_HL_CELLPADDING = 46, /* "cellpadding" */
  192. YYSYMBOL_HL_CELLSPACING = 47, /* "cellspacing" */
  193. YYSYMBOL_HL_COLOR = 48, /* "color" */
  194. YYSYMBOL_HL_COLUMNS = 49, /* "columns" */
  195. YYSYMBOL_HL_COLSPAN = 50, /* "colspan" */
  196. YYSYMBOL_HL_FACE = 51, /* "face" */
  197. YYSYMBOL_HL_FIXEDSIZE = 52, /* "fixedsize" */
  198. YYSYMBOL_HL_GRADIENTANGLE = 53, /* "gradientangle" */
  199. YYSYMBOL_HL_HEIGHT = 54, /* "height" */
  200. YYSYMBOL_HL_HREF = 55, /* "href" */
  201. YYSYMBOL_HL_ID = 56, /* "id" */
  202. YYSYMBOL_HL_PORT = 57, /* "port" */
  203. YYSYMBOL_HL_POINTSIZE = 58, /* "point-size" */
  204. YYSYMBOL_HL_ROWS = 59, /* "rows" */
  205. YYSYMBOL_HL_ROWSPAN = 60, /* "rowspan" */
  206. YYSYMBOL_HL_SCALE = 61, /* "scale" */
  207. YYSYMBOL_HL_SIDES = 62, /* "sides" */
  208. YYSYMBOL_HL_SRC = 63, /* "src" */
  209. YYSYMBOL_HL_STYLE = 64, /* "style" */
  210. YYSYMBOL_HL_TARGET = 65, /* "target" */
  211. YYSYMBOL_HL_TITLE = 66, /* "title" */
  212. YYSYMBOL_HL_TOOLTIP = 67, /* "tooltip" */
  213. YYSYMBOL_HL_VALIGN = 68, /* "valign" */
  214. YYSYMBOL_HL_WIDTH = 69, /* "width" */
  215. YYSYMBOL_YYACCEPT = 70, /* $accept */
  216. YYSYMBOL_begin = 71, /* begin */
  217. YYSYMBOL_htmlparser = 72, /* htmlparser */
  218. YYSYMBOL_htmlparser2 = 73, /* htmlparser2 */
  219. YYSYMBOL_items = 74, /* items */
  220. YYSYMBOL_item = 75, /* item */
  221. YYSYMBOL_76_1 = 76, /* $@1 */
  222. YYSYMBOL_77_2 = 77, /* $@2 */
  223. YYSYMBOL_78_3 = 78, /* $@3 */
  224. YYSYMBOL_79_4 = 79, /* $@4 */
  225. YYSYMBOL_80_5 = 80, /* $@5 */
  226. YYSYMBOL_fonttab2 = 81, /* fonttab2 */
  227. YYSYMBOL_font = 82, /* font */
  228. YYSYMBOL_83_6 = 83, /* $@6 */
  229. YYSYMBOL_italic = 84, /* italic */
  230. YYSYMBOL_overline = 85, /* overline */
  231. YYSYMBOL_bold = 86, /* bold */
  232. YYSYMBOL_underline = 87, /* underline */
  233. YYSYMBOL_tabe = 88, /* tabe */
  234. YYSYMBOL_tab = 89, /* tab */
  235. YYSYMBOL_90_7 = 90, /* $@7 */
  236. YYSYMBOL_rows = 91, /* rows */
  237. YYSYMBOL_92_8 = 92, /* $@8 */
  238. YYSYMBOL_93_9 = 93, /* $@9 */
  239. YYSYMBOL_row = 94, /* row */
  240. YYSYMBOL_95_10 = 95, /* $@10 */
  241. YYSYMBOL_cells = 96, /* cells */
  242. YYSYMBOL_97_11 = 97, /* $@11 */
  243. YYSYMBOL_98_12 = 98, /* $@12 */
  244. YYSYMBOL_cell = 99, /* cell */
  245. YYSYMBOL_cellimg = 100, /* cellimg */
  246. YYSYMBOL_celltd = 101, /* celltd */
  247. YYSYMBOL_table_arg = 102, /* table_arg */
  248. YYSYMBOL_table_1arg = 103, /* table_1arg */
  249. YYSYMBOL_td_arg = 104, /* td_arg */
  250. YYSYMBOL_td_1arg = 105, /* td_1arg */
  251. YYSYMBOL_img_arg = 106, /* img_arg */
  252. YYSYMBOL_img_1arg = 107, /* img_1arg */
  253. YYSYMBOL_br_arg = 108, /* br_arg */
  254. YYSYMBOL_br_1arg = 109, /* br_1arg */
  255. YYSYMBOL_font_arg = 110, /* font_arg */
  256. YYSYMBOL_font_1arg = 111 /* font_1arg */
  257. };
  258. typedef enum yysymbol_kind_t yysymbol_kind_t;
  259. #ifdef short
  260. #undef short
  261. #endif
  262. /* On compilers that do not define __PTRDIFF_MAX__ etc., make sure
  263. <limits.h> and (if available) <stdint.h> are included
  264. so that the code can choose integer types of a good width. */
  265. #ifndef __PTRDIFF_MAX__
  266. #include <limits.h> /* INFRINGES ON USER NAME SPACE */
  267. #if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
  268. #include <stdint.h> /* INFRINGES ON USER NAME SPACE */
  269. #define YY_STDINT_H
  270. #endif
  271. #endif
  272. /* Narrow types that promote to a signed type and that can represent a
  273. signed or unsigned integer of at least N bits. In tables they can
  274. save space and decrease cache pressure. Promoting to a signed type
  275. helps avoid bugs in integer arithmetic. */
  276. #ifdef __INT_LEAST8_MAX__
  277. typedef __INT_LEAST8_TYPE__ yytype_int8;
  278. #elif defined YY_STDINT_H
  279. typedef int_least8_t yytype_int8;
  280. #else
  281. typedef signed char yytype_int8;
  282. #endif
  283. #ifdef __INT_LEAST16_MAX__
  284. typedef __INT_LEAST16_TYPE__ yytype_int16;
  285. #elif defined YY_STDINT_H
  286. typedef int_least16_t yytype_int16;
  287. #else
  288. typedef short yytype_int16;
  289. #endif
  290. /* Work around bug in HP-UX 11.23, which defines these macros
  291. incorrectly for preprocessor constants. This workaround can likely
  292. be removed in 2023, as HPE has promised support for HP-UX 11.23
  293. (aka HP-UX 11i v2) only through the end of 2022; see Table 2 of
  294. <https://h20195.www2.hpe.com/V2/getpdf.aspx/4AA4-7673ENW.pdf>. */
  295. #ifdef __hpux
  296. #undef UINT_LEAST8_MAX
  297. #undef UINT_LEAST16_MAX
  298. #define UINT_LEAST8_MAX 255
  299. #define UINT_LEAST16_MAX 65535
  300. #endif
  301. #if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__
  302. typedef __UINT_LEAST8_TYPE__ yytype_uint8;
  303. #elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \
  304. && UINT_LEAST8_MAX <= INT_MAX)
  305. typedef uint_least8_t yytype_uint8;
  306. #elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX
  307. typedef unsigned char yytype_uint8;
  308. #else
  309. typedef short yytype_uint8;
  310. #endif
  311. #if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__
  312. typedef __UINT_LEAST16_TYPE__ yytype_uint16;
  313. #elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \
  314. && UINT_LEAST16_MAX <= INT_MAX)
  315. typedef uint_least16_t yytype_uint16;
  316. #elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX
  317. typedef unsigned short yytype_uint16;
  318. #else
  319. typedef int yytype_uint16;
  320. #endif
  321. #ifndef YYPTRDIFF_T
  322. #if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__
  323. #define YYPTRDIFF_T __PTRDIFF_TYPE__
  324. #define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__
  325. #elif defined PTRDIFF_MAX
  326. #ifndef ptrdiff_t
  327. #include <stddef.h> /* INFRINGES ON USER NAME SPACE */
  328. #endif
  329. #define YYPTRDIFF_T ptrdiff_t
  330. #define YYPTRDIFF_MAXIMUM PTRDIFF_MAX
  331. #else
  332. #define YYPTRDIFF_T long
  333. #define YYPTRDIFF_MAXIMUM LONG_MAX
  334. #endif
  335. #endif
  336. #ifndef YYSIZE_T
  337. #ifdef __SIZE_TYPE__
  338. #define YYSIZE_T __SIZE_TYPE__
  339. #elif defined size_t
  340. #define YYSIZE_T size_t
  341. #elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
  342. #include <stddef.h> /* INFRINGES ON USER NAME SPACE */
  343. #define YYSIZE_T size_t
  344. #else
  345. #define YYSIZE_T unsigned
  346. #endif
  347. #endif
  348. #define YYSIZE_MAXIMUM \
  349. YY_CAST (YYPTRDIFF_T, \
  350. (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1) \
  351. ? YYPTRDIFF_MAXIMUM \
  352. : YY_CAST (YYSIZE_T, -1)))
  353. #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X))
  354. /* Stored state numbers (used for stacks). */
  355. typedef yytype_int16 yy_state_t;
  356. /* State numbers in computations. */
  357. typedef int yy_state_fast_t;
  358. #ifndef YY_
  359. #if defined YYENABLE_NLS && YYENABLE_NLS
  360. #if ENABLE_NLS
  361. #include <libintl.h> /* INFRINGES ON USER NAME SPACE */
  362. #define YY_(Msgid) dgettext ("bison-runtime", Msgid)
  363. #endif
  364. #endif
  365. #ifndef YY_
  366. #define YY_(Msgid) Msgid
  367. #endif
  368. #endif
  369. #ifndef YY_ATTRIBUTE_PURE
  370. #if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__)
  371. #define YY_ATTRIBUTE_PURE __attribute__ ((__pure__))
  372. #else
  373. #define YY_ATTRIBUTE_PURE
  374. #endif
  375. #endif
  376. #ifndef YY_ATTRIBUTE_UNUSED
  377. #if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__)
  378. #define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__))
  379. #else
  380. #define YY_ATTRIBUTE_UNUSED
  381. #endif
  382. #endif
  383. /* Suppress unused-variable warnings by "using" E. */
  384. #if ! defined lint || defined __GNUC__
  385. #define YY_USE(E) ((void) (E))
  386. #else
  387. #define YY_USE(E) /* empty */
  388. #endif
  389. #if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
  390. /* Suppress an incorrect diagnostic about yylval being uninitialized. */
  391. #define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
  392. _Pragma ("GCC diagnostic push") \
  393. _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
  394. _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
  395. #define YY_IGNORE_MAYBE_UNINITIALIZED_END \
  396. _Pragma ("GCC diagnostic pop")
  397. #else
  398. #define YY_INITIAL_VALUE(Value) Value
  399. #endif
  400. #ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
  401. #define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
  402. #define YY_IGNORE_MAYBE_UNINITIALIZED_END
  403. #endif
  404. #ifndef YY_INITIAL_VALUE
  405. #define YY_INITIAL_VALUE(Value) /* Nothing. */
  406. #endif
  407. #if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__
  408. #define YY_IGNORE_USELESS_CAST_BEGIN \
  409. _Pragma ("GCC diagnostic push") \
  410. _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"")
  411. #define YY_IGNORE_USELESS_CAST_END \
  412. _Pragma ("GCC diagnostic pop")
  413. #endif
  414. #ifndef YY_IGNORE_USELESS_CAST_BEGIN
  415. #define YY_IGNORE_USELESS_CAST_BEGIN
  416. #define YY_IGNORE_USELESS_CAST_END
  417. #endif
  418. #define YY_ASSERT(E) ((void) (0 && (E)))
  419. #if !defined yyoverflow
  420. /* The parser invokes alloca or malloc; define the necessary symbols. */
  421. #ifdef YYSTACK_USE_ALLOCA
  422. #if YYSTACK_USE_ALLOCA
  423. #ifdef __GNUC__
  424. #define YYSTACK_ALLOC __builtin_alloca
  425. #elif defined __BUILTIN_VA_ARG_INCR
  426. #include <alloca.h> /* INFRINGES ON USER NAME SPACE */
  427. #elif defined _AIX
  428. #define YYSTACK_ALLOC __alloca
  429. #elif defined _MSC_VER
  430. #include <malloc.h> /* INFRINGES ON USER NAME SPACE */
  431. #define alloca _alloca
  432. #else
  433. #define YYSTACK_ALLOC alloca
  434. #if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
  435. #include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
  436. /* Use EXIT_SUCCESS as a witness for stdlib.h. */
  437. #ifndef EXIT_SUCCESS
  438. #define EXIT_SUCCESS 0
  439. #endif
  440. #endif
  441. #endif
  442. #endif
  443. #endif
  444. #ifdef YYSTACK_ALLOC
  445. /* Pacify GCC's 'empty if-body' warning. */
  446. #define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
  447. #ifndef YYSTACK_ALLOC_MAXIMUM
  448. /* The OS might guarantee only one guard page at the bottom of the stack,
  449. and a page size can be as small as 4096 bytes. So we cannot safely
  450. invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
  451. to allow for a few compiler-allocated temporary stack slots. */
  452. #define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
  453. #endif
  454. #else
  455. #define YYSTACK_ALLOC YYMALLOC
  456. #define YYSTACK_FREE YYFREE
  457. #ifndef YYSTACK_ALLOC_MAXIMUM
  458. #define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
  459. #endif
  460. #if (defined __cplusplus && ! defined EXIT_SUCCESS \
  461. && ! ((defined YYMALLOC || defined malloc) \
  462. && (defined YYFREE || defined free)))
  463. #include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
  464. #ifndef EXIT_SUCCESS
  465. #define EXIT_SUCCESS 0
  466. #endif
  467. #endif
  468. #ifndef YYMALLOC
  469. #define YYMALLOC malloc
  470. #if ! defined malloc && ! defined EXIT_SUCCESS
  471. void *malloc(YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
  472. #endif
  473. #endif
  474. #ifndef YYFREE
  475. #define YYFREE free
  476. #if ! defined free && ! defined EXIT_SUCCESS
  477. void free(void *); /* INFRINGES ON USER NAME SPACE */
  478. #endif
  479. #endif
  480. #endif
  481. #endif /* !defined yyoverflow */
  482. #if (! defined yyoverflow \
  483. && (! defined __cplusplus \
  484. || (defined HLYSTYPE_IS_TRIVIAL && HLYSTYPE_IS_TRIVIAL)))
  485. /* A type that is properly aligned for any stack member. */
  486. union yyalloc {
  487. yy_state_t yyss_alloc;
  488. YYSTYPE yyvs_alloc;
  489. };
  490. /* The size of the maximum gap between one aligned stack and the next. */
  491. #define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1)
  492. /* The size of an array large to enough to hold all stacks, each with
  493. N elements. */
  494. #define YYSTACK_BYTES(N) \
  495. ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \
  496. + YYSTACK_GAP_MAXIMUM)
  497. #define YYCOPY_NEEDED 1
  498. /* Relocate STACK from its old location to the new one. The
  499. local variables YYSIZE and YYSTACKSIZE give the old and new number of
  500. elements in the stack, and YYPTR gives the new location of the
  501. stack. Advance YYPTR to a properly aligned location for the next
  502. stack. */
  503. #define YYSTACK_RELOCATE(Stack_alloc, Stack) \
  504. do \
  505. { \
  506. YYPTRDIFF_T yynewbytes; \
  507. YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
  508. Stack = &yyptr->Stack_alloc; \
  509. yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \
  510. yyptr += yynewbytes / YYSIZEOF (*yyptr); \
  511. } \
  512. while (0)
  513. #endif
  514. #if defined YYCOPY_NEEDED && YYCOPY_NEEDED
  515. /* Copy COUNT objects from SRC to DST. The source and destination do
  516. not overlap. */
  517. #ifndef YYCOPY
  518. #if defined __GNUC__ && 1 < __GNUC__
  519. #define YYCOPY(Dst, Src, Count) \
  520. __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src)))
  521. #else
  522. #define YYCOPY(Dst, Src, Count) \
  523. do \
  524. { \
  525. YYPTRDIFF_T yyi; \
  526. for (yyi = 0; yyi < (Count); yyi++) \
  527. (Dst)[yyi] = (Src)[yyi]; \
  528. } \
  529. while (0)
  530. #endif
  531. #endif
  532. #endif /* !YYCOPY_NEEDED */
  533. /* YYFINAL -- State number of the termination state. */
  534. #define YYFINAL 36
  535. /* YYLAST -- Last index in YYTABLE. */
  536. #define YYLAST 417
  537. /* YYNTOKENS -- Number of terminals. */
  538. #define YYNTOKENS 70
  539. /* YYNNTS -- Number of nonterminals. */
  540. #define YYNNTS 42
  541. /* YYNRULES -- Number of rules. */
  542. #define YYNRULES 125
  543. /* YYNSTATES -- Number of states. */
  544. #define YYNSTATES 323
  545. /* YYMAXUTOK -- Last valid token kind. */
  546. #define YYMAXUTOK 324
  547. /* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
  548. as returned by yylex, with out-of-bounds checking. */
  549. #define YYTRANSLATE(YYX) \
  550. (0 <= (YYX) && (YYX) <= YYMAXUTOK \
  551. ? YY_CAST (yysymbol_kind_t, yytranslate[YYX]) \
  552. : YYSYMBOL_YYUNDEF)
  553. /* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
  554. as returned by yylex. */
  555. static const yytype_int8 yytranslate[] = {
  556. 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  557. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  558. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  559. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  560. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  561. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  562. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  563. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  564. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  565. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  566. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  567. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  568. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  569. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  570. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  571. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  572. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  573. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  574. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  575. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  576. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  577. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  578. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  579. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  580. 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
  581. 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
  582. 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
  583. 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
  584. 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
  585. 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
  586. 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
  587. 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
  588. 65, 66, 67, 68, 69
  589. };
  590. #if HLYDEBUG
  591. /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
  592. static const yytype_int16 yyrline[] = {
  593. 0, 280, 280, 285, 286, 291, 292, 297, 298, 313,
  594. 314, 314, 315, 315, 316, 317, 318, 319, 320, 321,
  595. 321, 322, 322, 323, 323, 337, 338, 339, 340, 341,
  596. 342, 346, 346, 350, 354, 358, 362, 367, 368, 373,
  597. 373, 378, 379, 380, 380, 381, 381, 386, 386, 391,
  598. 392, 393, 393, 394, 394, 402, 403, 404, 405, 409,
  599. 413, 440, 441, 445, 446, 447, 448, 449, 450, 451,
  600. 452, 453, 454, 455, 456, 457, 458, 459, 460, 461,
  601. 462, 463, 464, 465, 466, 467, 494, 495, 499, 500,
  602. 501, 502, 503, 504, 505, 506, 507, 508, 509, 510,
  603. 511, 512, 513, 514, 515, 516, 517, 518, 519, 520,
  604. 521, 530, 531, 535, 536, 537, 544, 545, 549, 550,
  605. 559, 560, 564, 565, 566, 567
  606. };
  607. #endif
  608. /** Accessing symbol of state STATE. */
  609. #define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State])
  610. #if HLYDEBUG || 1
  611. /* The user-facing name of the symbol whose (internal) number is
  612. YYSYMBOL. No bounds checking. */
  613. static const char *yysymbol_name(yysymbol_kind_t yysymbol) YY_ATTRIBUTE_UNUSED;
  614. /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
  615. First, the terminals, then, starting at YYNTOKENS, nonterminals. */
  616. static const char *const yytname[] = {
  617. "\"end of file\"", "error", "\"invalid token\"", "\"stringdata\"",
  618. "\"<html\"", "\"</html\"", "\"<b\"", "\"</b\"", "\"<br\"", "\"</br\"",
  619. "\"<font\"", "\"</font\"", "\"<hr\"", "\"</hr\"", "\"<i\"", "\"</i\"",
  620. "\"<img\"", "\"</img\"", "\"<o\"", "\"</o\"", "\"<s\"", "\"</s\"",
  621. "\"<sub\"", "\"</sub\"", "\"<sup\"", "\"</sup\"", "\"<table\"",
  622. "\"</table\"", "\"<td\"", "\"</td\"", "\"<tr\"", "\"</tr\"", "\"<u\"",
  623. "\"</u\"", "\"<vr\"", "\"</vr\"", "\"/>\"", "\">\"", "\"=\"",
  624. "\"string\"", "\"text\"", "\"align\"", "\"balign\"", "\"bgcolor\"",
  625. "\"border\"", "\"cellborder\"", "\"cellpadding\"", "\"cellspacing\"",
  626. "\"color\"", "\"columns\"", "\"colspan\"", "\"face\"", "\"fixedsize\"",
  627. "\"gradientangle\"", "\"height\"", "\"href\"", "\"id\"", "\"port\"",
  628. "\"point-size\"", "\"rows\"", "\"rowspan\"", "\"scale\"", "\"sides\"",
  629. "\"src\"", "\"style\"", "\"target\"", "\"title\"", "\"tooltip\"",
  630. "\"valign\"", "\"width\"", "$accept", "begin", "htmlparser",
  631. "htmlparser2", "items", "item", "$@1", "$@2", "$@3", "$@4", "$@5",
  632. "fonttab2", "font", "$@6", "italic", "overline", "bold", "underline",
  633. "tabe", "tab", "$@7", "rows", "$@8", "$@9", "row", "$@10", "cells",
  634. "$@11", "$@12", "cell", "cellimg", "celltd", "table_arg", "table_1arg",
  635. "td_arg", "td_1arg", "img_arg", "img_1arg", "br_arg", "br_1arg",
  636. "font_arg", "font_1arg", YY_NULLPTR
  637. };
  638. static const char *yysymbol_name(yysymbol_kind_t yysymbol)
  639. {
  640. return yytname[yysymbol];
  641. }
  642. #endif
  643. #ifdef YYPRINT
  644. /* YYTOKNUM[NUM] -- (External) token number corresponding to the
  645. (internal) symbol number NUM (which must be that of a token). */
  646. static const yytype_int16 yytoknum[] = {
  647. 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
  648. 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
  649. 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
  650. 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
  651. 295, 296, 297, 298, 299, 300, 301, 302, 303, 304,
  652. 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
  653. 315, 316, 317, 318, 319, 320, 321, 322, 323, 324
  654. };
  655. #endif
  656. #define YYPACT_NINF (-198)
  657. #define yypact_value_is_default(Yyn) \
  658. ((Yyn) == YYPACT_NINF)
  659. #define YYTABLE_NINF (-38)
  660. #define yytable_value_is_error(Yyn) \
  661. 0
  662. /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
  663. STATE-NUM. */
  664. static const yytype_int16 yypact[] = {
  665. 171, -18, -20, -2, 6, -198, 8, 9, 11, 12,
  666. 17, 18, 37, -198, -198, 326, -198, -198, 349, 349,
  667. 349, 349, 349, 33, -198, 349, -198, -198, -198, -198,
  668. -198, -198, -198, -198, -198, -198, -198, -198, -198, 326,
  669. 326, 326, 326, 326, 191, 52, 221, 54, 241, 46,
  670. 261, 60, 50, 38, -198, 68, 66, 21, 132, 326,
  671. 326, 326, 39, 43, 49, 57, 58, 65, 70, 78,
  672. 79, 85, -198, 89, 91, -198, 97, 98, -198, -198,
  673. 102, 111, 113, 117, -198, 274, 294, 317, -198, -198,
  674. -198, -198, -198, -198, -198, -198, -198, -198, 44, -198,
  675. -198, 118, 120, 122, 124, 128, 131, 134, 141, 145,
  676. 135, 146, 148, 149, 150, 154, 158, 160, 162, 166,
  677. 168, 169, 170, 172, 174, 176, 178, 179, 187, 188,
  678. 190, 192, 194, 195, -198, -198, -198, -198, -198, -198,
  679. -198, -198, -198, -198, 197, 126, -198, 198, 199, 201,
  680. 203, 207, 209, 211, 213, 215, 217, 218, 219, 223,
  681. 227, 231, 233, 235, 237, 239, 247, 248, 250, 251,
  682. -198, -16, 254, -198, -198, -198, -198, -198, -198, -198,
  683. -198, -198, -198, -198, -198, -198, -198, -198, -198, -198,
  684. -198, -198, -198, -198, -198, -198, -198, 271, -198, 288,
  685. 300, -198, -12, -198, -198, 135, 268, -198, -198, 270,
  686. -13, -198, 77, -198, -198, -198, -198, 275, 144, 273,
  687. 277, 281, 283, 284, 286, 290, 292, 295, 305, 307,
  688. 309, 313, 315, 316, 318, 322, 323, 324, 327, 328,
  689. 330, 332, -198, 135, 271, 272, -198, 276, 335, -198,
  690. 299, 333, 340, 341, 343, 344, 345, 346, 347, 348,
  691. 350, 351, 352, 353, 354, 355, 357, 358, 359, 360,
  692. 361, 362, 363, -198, -198, -198, -198, 366, -22, -198,
  693. -198, -198, -198, -198, -198, -198, -198, -198, -198, -198,
  694. -198, -198, -198, -198, -198, -198, -198, -198, -198, -198,
  695. -198, -198, 271, -198, 375, 371, 367, 368, 369, -198,
  696. -198, 372, 373, 374, 376, 377, -198, 379, -198, -198,
  697. -198, 380, -198
  698. };
  699. /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
  700. Performed when YYTABLE does not specify something else to do. Zero
  701. means the default is an error. */
  702. static const yytype_int8 yydefact[] = {
  703. 38, 9, 0, 0, 10, 31, 0, 0, 0, 0,
  704. 0, 0, 0, 2, 4, 5, 8, 6, 38, 38,
  705. 38, 38, 38, 0, 25, 38, 35, 12, 117, 121,
  706. 33, 34, 23, 19, 21, 36, 1, 9, 7, 0,
  707. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  708. 0, 0, 0, 0, 39, 0, 0, 0, 0, 0,
  709. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  710. 0, 0, 62, 0, 0, 11, 0, 0, 116, 32,
  711. 0, 0, 0, 0, 120, 0, 0, 0, 14, 26,
  712. 15, 27, 18, 30, 16, 28, 17, 29, 0, 3,
  713. 13, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  714. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  715. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  716. 0, 0, 0, 0, 61, 119, 118, 125, 122, 123,
  717. 124, 24, 20, 22, 0, 0, 41, 0, 0, 0,
  718. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  719. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  720. 47, 0, 0, 42, 85, 63, 64, 65, 66, 67,
  721. 68, 69, 70, 71, 72, 73, 74, 75, 76, 77,
  722. 78, 79, 80, 81, 82, 83, 84, 0, 43, 0,
  723. 38, 60, 0, 49, 87, 0, 0, 37, 40, 0,
  724. 0, 50, 0, 44, 45, 48, 51, 0, 38, 0,
  725. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  726. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  727. 0, 0, 86, 0, 0, 0, 59, 0, 0, 112,
  728. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  729. 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  730. 0, 0, 0, 46, 52, 53, 58, 0, 0, 110,
  731. 88, 89, 90, 91, 92, 93, 94, 95, 96, 97,
  732. 98, 99, 100, 101, 102, 103, 104, 105, 106, 107,
  733. 108, 109, 0, 55, 0, 0, 0, 0, 0, 111,
  734. 54, 0, 0, 0, 0, 0, 56, 0, 115, 113,
  735. 114, 0, 57
  736. };
  737. /* YYPGOTO[NTERM-NUM]. */
  738. static const yytype_int16 yypgoto[] = {
  739. -198, -198, 177, 386, -9, -8, -198, -198, -198, -198,
  740. -198, -198, 0, -198, 1, 2, 3, 4, 212, 356,
  741. -198, -198, -198, -198, -139, -198, -198, -198, -198, -197,
  742. -198, -198, -198, -198, -198, -198, -198, -198, -198, -198,
  743. -198, -198
  744. };
  745. /* YYDEFGOTO[NTERM-NUM]. */
  746. static const yytype_int16 yydefgoto[] = {
  747. 0, 12, 13, 14, 15, 16, 28, 56, 60, 61,
  748. 59, 17, 39, 29, 40, 41, 42, 43, 23, 24,
  749. 72, 145, 205, 243, 146, 197, 202, 244, 302, 203,
  750. 249, 204, 98, 134, 212, 242, 278, 309, 57, 78,
  751. 58, 84
  752. };
  753. /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
  754. positive, shift that token. If negative, reduce the rule whose
  755. number is the opposite. If YYTABLE_NINF, syntax error. */
  756. static const yytype_int16 yytable[] = {
  757. 18, 19, 20, 21, 22, 211, 173, 38, -37, 44,
  758. 46, 48, 50, 52, 304, 305, 201, 25, 306, 209,
  759. 198, 199, 210, 216, 217, 18, 19, 20, 21, 22,
  760. 44, 46, 48, 50, 52, 26, 38, 36, 38, 307,
  761. 38, 308, 38, 27, 38, 30, 31, 274, 32, 33,
  762. 85, 86, 87, 37, 34, 35, 3, 75, 4, 54,
  763. 5, 76, 77, 63, 6, 67, 213, 69, 7, 65,
  764. 8, 71, 9, 73, 10, 74, 88, 38, 38, 38,
  765. 89, 110, 11, 70, 111, 112, 90, 113, 114, 115,
  766. 116, 117, 118, 119, 91, 92, 120, 121, 122, 123,
  767. 124, 125, 93, 126, 273, 310, 127, 94, 128, 129,
  768. 130, 131, 132, 133, 218, 95, 96, 219, 220, 221,
  769. 222, 223, 97, 224, 225, 226, 99, 227, 100, 228,
  770. 229, 230, 231, 232, 233, 101, 102, 234, 171, 235,
  771. 103, 236, 237, 238, 239, 240, 241, 1, 2, 104,
  772. 3, 105, 4, 172, 5, 106, 144, 135, 6, 136,
  773. 246, 137, 7, 138, 8, 144, 9, 139, 10, 79,
  774. 140, 141, 80, 247, 1, 2, 11, 3, 142, 4,
  775. 81, 5, 143, 82, 147, 6, 148, 149, 150, 7,
  776. 83, 8, 151, 9, 37, 10, 152, 3, 153, 4,
  777. 154, 5, 62, 11, 155, 6, 156, 157, 158, 7,
  778. 159, 8, 160, 9, 161, 10, 162, 163, 18, 19,
  779. 20, 21, 22, 11, 37, 164, 165, 3, 166, 4,
  780. 167, 5, 168, 169, 170, 6, 64, 174, 175, 7,
  781. 176, 8, 177, 9, 37, 10, 178, 3, 179, 4,
  782. 180, 5, 181, 11, 182, 6, 183, 184, 185, 7,
  783. 66, 8, 186, 9, 37, 10, 187, 3, 68, 4,
  784. 188, 5, 189, 11, 190, 6, 191, 37, 192, 7,
  785. 3, 8, 4, 9, 5, 10, 193, 194, 6, 195,
  786. 196, 200, 7, 11, 8, 107, 9, 37, 10, 201,
  787. 3, 206, 4, 207, 5, 214, 11, 215, 6, 275,
  788. 245, 250, 7, 276, 8, 251, 9, 108, 10, 252,
  789. 37, 253, 254, 3, 255, 4, 11, 5, 256, 37,
  790. 257, 6, 3, 258, 4, 7, 5, 8, 279, 9,
  791. 6, 10, 109, 259, 7, 260, 8, 261, 9, 11,
  792. 10, 262, 1, 263, 264, 3, 265, 4, 11, 5,
  793. 266, 267, 268, 6, 277, 269, 270, 7, 271, 8,
  794. 272, 9, 280, 10, 45, 47, 49, 51, 53, 281,
  795. 282, 11, 283, 284, 285, 286, 287, 288, 312, 289,
  796. 290, 291, 292, 293, 294, 248, 295, 296, 297, 298,
  797. 299, 300, 301, 303, 311, 313, 314, 315, 321, 316,
  798. 317, 55, 208, 318, 0, 319, 320, 322
  799. };
  800. static const yytype_int16 yycheck[] = {
  801. 0, 0, 0, 0, 0, 202, 145, 15, 26, 18,
  802. 19, 20, 21, 22, 36, 37, 28, 37, 40, 31,
  803. 36, 37, 34, 36, 37, 25, 25, 25, 25, 25,
  804. 39, 40, 41, 42, 43, 37, 44, 0, 46, 61,
  805. 48, 63, 50, 37, 52, 37, 37, 244, 37, 37,
  806. 59, 60, 61, 3, 37, 37, 6, 36, 8, 26,
  807. 10, 40, 41, 11, 14, 19, 205, 7, 18, 15,
  808. 20, 33, 22, 5, 24, 9, 37, 85, 86, 87,
  809. 37, 37, 32, 33, 40, 41, 37, 43, 44, 45,
  810. 46, 47, 48, 49, 37, 37, 52, 53, 54, 55,
  811. 56, 57, 37, 59, 243, 302, 62, 37, 64, 65,
  812. 66, 67, 68, 69, 37, 37, 37, 40, 41, 42,
  813. 43, 44, 37, 46, 47, 48, 37, 50, 37, 52,
  814. 53, 54, 55, 56, 57, 38, 38, 60, 12, 62,
  815. 38, 64, 65, 66, 67, 68, 69, 3, 4, 38,
  816. 6, 38, 8, 27, 10, 38, 30, 39, 14, 39,
  817. 16, 39, 18, 39, 20, 30, 22, 39, 24, 37,
  818. 39, 37, 40, 29, 3, 4, 32, 6, 37, 8,
  819. 48, 10, 37, 51, 38, 14, 38, 38, 38, 18,
  820. 58, 20, 38, 22, 3, 24, 38, 6, 38, 8,
  821. 38, 10, 11, 32, 38, 14, 38, 38, 38, 18,
  822. 38, 20, 38, 22, 38, 24, 38, 38, 218, 218,
  823. 218, 218, 218, 32, 3, 38, 38, 6, 38, 8,
  824. 38, 10, 38, 38, 37, 14, 15, 39, 39, 18,
  825. 39, 20, 39, 22, 3, 24, 39, 6, 39, 8,
  826. 39, 10, 39, 32, 39, 14, 39, 39, 39, 18,
  827. 19, 20, 39, 22, 3, 24, 39, 6, 7, 8,
  828. 39, 10, 39, 32, 39, 14, 39, 3, 39, 18,
  829. 6, 20, 8, 22, 10, 24, 39, 39, 14, 39,
  830. 39, 37, 18, 32, 20, 21, 22, 3, 24, 28,
  831. 6, 13, 8, 3, 10, 37, 32, 37, 14, 37,
  832. 35, 38, 18, 37, 20, 38, 22, 23, 24, 38,
  833. 3, 38, 38, 6, 38, 8, 32, 10, 38, 3,
  834. 38, 14, 6, 38, 8, 18, 10, 20, 39, 22,
  835. 14, 24, 25, 38, 18, 38, 20, 38, 22, 32,
  836. 24, 38, 3, 38, 38, 6, 38, 8, 32, 10,
  837. 38, 38, 38, 14, 29, 38, 38, 18, 38, 20,
  838. 38, 22, 39, 24, 18, 19, 20, 21, 22, 39,
  839. 39, 32, 39, 39, 39, 39, 39, 39, 17, 39,
  840. 39, 39, 39, 39, 39, 218, 39, 39, 39, 39,
  841. 39, 39, 39, 37, 29, 38, 38, 38, 29, 37,
  842. 37, 25, 200, 39, -1, 39, 39, 37
  843. };
  844. /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
  845. symbol of state STATE-NUM. */
  846. static const yytype_int8 yystos[] = {
  847. 0, 3, 4, 6, 8, 10, 14, 18, 20, 22,
  848. 24, 32, 71, 72, 73, 74, 75, 81, 82, 84,
  849. 85, 86, 87, 88, 89, 37, 37, 37, 76, 83,
  850. 37, 37, 37, 37, 37, 37, 0, 3, 75, 82,
  851. 84, 85, 86, 87, 74, 89, 74, 89, 74, 89,
  852. 74, 89, 74, 89, 26, 73, 77, 108, 110, 80,
  853. 78, 79, 11, 11, 15, 15, 19, 19, 7, 7,
  854. 33, 33, 90, 5, 9, 36, 40, 41, 109, 37,
  855. 40, 48, 51, 58, 111, 74, 74, 74, 37, 37,
  856. 37, 37, 37, 37, 37, 37, 37, 37, 102, 37,
  857. 37, 38, 38, 38, 38, 38, 38, 21, 23, 25,
  858. 37, 40, 41, 43, 44, 45, 46, 47, 48, 49,
  859. 52, 53, 54, 55, 56, 57, 59, 62, 64, 65,
  860. 66, 67, 68, 69, 103, 39, 39, 39, 39, 39,
  861. 39, 37, 37, 37, 30, 91, 94, 38, 38, 38,
  862. 38, 38, 38, 38, 38, 38, 38, 38, 38, 38,
  863. 38, 38, 38, 38, 38, 38, 38, 38, 38, 38,
  864. 37, 12, 27, 94, 39, 39, 39, 39, 39, 39,
  865. 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
  866. 39, 39, 39, 39, 39, 39, 39, 95, 36, 37,
  867. 37, 28, 96, 99, 101, 92, 13, 3, 88, 31,
  868. 34, 99, 104, 94, 37, 37, 36, 37, 37, 40,
  869. 41, 42, 43, 44, 46, 47, 48, 50, 52, 53,
  870. 54, 55, 56, 57, 60, 62, 64, 65, 66, 67,
  871. 68, 69, 105, 93, 97, 35, 16, 29, 72, 100,
  872. 38, 38, 38, 38, 38, 38, 38, 38, 38, 38,
  873. 38, 38, 38, 38, 38, 38, 38, 38, 38, 38,
  874. 38, 38, 38, 94, 99, 37, 37, 29, 106, 39,
  875. 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
  876. 39, 39, 39, 39, 39, 39, 39, 39, 39, 39,
  877. 39, 39, 98, 37, 36, 37, 40, 61, 63, 107,
  878. 99, 29, 17, 38, 38, 38, 37, 37, 39, 39,
  879. 39, 29, 37
  880. };
  881. /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
  882. static const yytype_int8 yyr1[] = {
  883. 0, 70, 71, 72, 72, 73, 73, 74, 74, 75,
  884. 76, 75, 77, 75, 75, 75, 75, 75, 75, 78,
  885. 75, 79, 75, 80, 75, 81, 81, 81, 81, 81,
  886. 81, 83, 82, 84, 85, 86, 87, 88, 88, 90,
  887. 89, 91, 91, 92, 91, 93, 91, 95, 94, 96,
  888. 96, 97, 96, 98, 96, 99, 99, 99, 99, 100,
  889. 101, 102, 102, 103, 103, 103, 103, 103, 103, 103,
  890. 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
  891. 103, 103, 103, 103, 103, 103, 104, 104, 105, 105,
  892. 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
  893. 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
  894. 105, 106, 106, 107, 107, 107, 108, 108, 109, 109,
  895. 110, 110, 111, 111, 111, 111
  896. };
  897. /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
  898. static const yytype_int8 yyr2[] = {
  899. 0, 2, 1, 5, 1, 1, 1, 2, 1, 1,
  900. 0, 4, 0, 5, 4, 4, 4, 4, 4, 0,
  901. 6, 0, 6, 0, 6, 1, 4, 4, 4, 4,
  902. 4, 0, 4, 2, 2, 2, 2, 1, 0, 0,
  903. 9, 1, 2, 0, 5, 0, 7, 0, 6, 1,
  904. 2, 0, 5, 0, 7, 6, 8, 10, 5, 1,
  905. 1, 2, 0, 3, 3, 3, 3, 3, 3, 3,
  906. 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
  907. 3, 3, 3, 3, 3, 3, 2, 0, 3, 3,
  908. 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
  909. 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
  910. 3, 2, 0, 3, 3, 3, 2, 0, 3, 3,
  911. 2, 0, 3, 3, 3, 3
  912. };
  913. enum { YYENOMEM = -2 };
  914. #define yyerrok (yyerrstatus = 0)
  915. #define yyclearin (yychar = HLYEMPTY)
  916. #define YYACCEPT goto yyacceptlab
  917. #define YYABORT goto yyabortlab
  918. #define YYERROR goto yyerrorlab
  919. #define YYRECOVERING() (!!yyerrstatus)
  920. #define YYBACKUP(Token, Value) \
  921. do \
  922. if (yychar == HLYEMPTY) \
  923. { \
  924. yychar = (Token); \
  925. yylval = (Value); \
  926. YYPOPSTACK (yylen); \
  927. yystate = *yyssp; \
  928. goto yybackup; \
  929. } \
  930. else \
  931. { \
  932. yyerror (YY_("syntax error: cannot back up")); \
  933. YYERROR; \
  934. } \
  935. while (0)
  936. /* Backward compatibility with an undocumented macro.
  937. Use HLYerror or HLYUNDEF. */
  938. #define YYERRCODE HLYUNDEF
  939. /* Enable debugging if requested. */
  940. #if HLYDEBUG
  941. #ifndef YYFPRINTF
  942. #include <stdio.h> /* INFRINGES ON USER NAME SPACE */
  943. #define YYFPRINTF fprintf
  944. #endif
  945. #define YYDPRINTF(Args) \
  946. do { \
  947. if (yydebug) \
  948. YYFPRINTF Args; \
  949. } while (0)
  950. /* This macro is provided for backward compatibility. */
  951. #ifndef YY_LOCATION_PRINT
  952. #define YY_LOCATION_PRINT(File, Loc) ((void) 0)
  953. #endif
  954. #define YY_SYMBOL_PRINT(Title, Kind, Value, Location) \
  955. do { \
  956. if (yydebug) \
  957. { \
  958. YYFPRINTF (stderr, "%s ", Title); \
  959. yy_symbol_print (stderr, \
  960. Kind, Value); \
  961. YYFPRINTF (stderr, "\n"); \
  962. } \
  963. } while (0)
  964. /*-----------------------------------.
  965. | Print this symbol's value on YYO. |
  966. `-----------------------------------*/
  967. static void yy_symbol_value_print(FILE * yyo, yysymbol_kind_t yykind, YYSTYPE const *const yyvaluep)
  968. {
  969. FILE *yyoutput = yyo;
  970. YY_USE(yyoutput);
  971. if (!yyvaluep)
  972. return;
  973. #ifdef YYPRINT
  974. if (yykind < YYNTOKENS)
  975. YYPRINT(yyo, yytoknum[yykind], *yyvaluep);
  976. #endif
  977. YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN YY_USE(yykind);
  978. YY_IGNORE_MAYBE_UNINITIALIZED_END}
  979. /*---------------------------.
  980. | Print this symbol on YYO. |
  981. `---------------------------*/
  982. static void yy_symbol_print(FILE * yyo, yysymbol_kind_t yykind, YYSTYPE const *const yyvaluep)
  983. {
  984. YYFPRINTF(yyo, "%s %s (", yykind < YYNTOKENS ? "token" : "nterm", yysymbol_name(yykind));
  985. yy_symbol_value_print(yyo, yykind, yyvaluep);
  986. YYFPRINTF(yyo, ")");
  987. }
  988. /*------------------------------------------------------------------.
  989. | yy_stack_print -- Print the state stack from its BOTTOM up to its |
  990. | TOP (included). |
  991. `------------------------------------------------------------------*/
  992. static void yy_stack_print(yy_state_t * yybottom, yy_state_t * yytop)
  993. {
  994. YYFPRINTF(stderr, "Stack now");
  995. for (; yybottom <= yytop; yybottom++) {
  996. int yybot = *yybottom;
  997. YYFPRINTF(stderr, " %d", yybot);
  998. }
  999. YYFPRINTF(stderr, "\n");
  1000. }
  1001. #define YY_STACK_PRINT(Bottom, Top) \
  1002. do { \
  1003. if (yydebug) \
  1004. yy_stack_print ((Bottom), (Top)); \
  1005. } while (0)
  1006. /*------------------------------------------------.
  1007. | Report that the YYRULE is going to be reduced. |
  1008. `------------------------------------------------*/
  1009. static void yy_reduce_print(yy_state_t * yyssp, YYSTYPE * yyvsp, int yyrule)
  1010. {
  1011. int yylno = yyrline[yyrule];
  1012. int yynrhs = yyr2[yyrule];
  1013. int yyi;
  1014. YYFPRINTF(stderr, "Reducing stack by rule %d (line %d):\n", yyrule - 1, yylno);
  1015. /* The symbols being reduced. */
  1016. for (yyi = 0; yyi < yynrhs; yyi++) {
  1017. YYFPRINTF(stderr, " $%d = ", yyi + 1);
  1018. yy_symbol_print(stderr, YY_ACCESSING_SYMBOL(+yyssp[yyi + 1 - yynrhs]), &yyvsp[(yyi + 1) - (yynrhs)]);
  1019. YYFPRINTF(stderr, "\n");
  1020. }
  1021. }
  1022. #define YY_REDUCE_PRINT(Rule) \
  1023. do { \
  1024. if (yydebug) \
  1025. yy_reduce_print (yyssp, yyvsp, Rule); \
  1026. } while (0)
  1027. /* Nonzero means print parse trace. It is left uninitialized so that
  1028. multiple parsers can coexist. */
  1029. int yydebug;
  1030. #else /* !HLYDEBUG */
  1031. #define YYDPRINTF(Args) ((void) 0)
  1032. #define YY_SYMBOL_PRINT(Title, Kind, Value, Location)
  1033. #define YY_STACK_PRINT(Bottom, Top)
  1034. #define YY_REDUCE_PRINT(Rule)
  1035. #endif /* !HLYDEBUG */
  1036. /* YYINITDEPTH -- initial size of the parser's stacks. */
  1037. #ifndef YYINITDEPTH
  1038. #define YYINITDEPTH 200
  1039. #endif
  1040. /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
  1041. if the built-in stack extension method is used).
  1042. Do not make this value too large; the results are undefined if
  1043. YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
  1044. evaluated with infinite-precision integer arithmetic. */
  1045. #ifndef YYMAXDEPTH
  1046. #define YYMAXDEPTH 10000
  1047. #endif
  1048. /*-----------------------------------------------.
  1049. | Release the memory associated to this symbol. |
  1050. `-----------------------------------------------*/
  1051. static void yydestruct(const char *yymsg, yysymbol_kind_t yykind, YYSTYPE * yyvaluep)
  1052. {
  1053. YY_USE(yyvaluep);
  1054. if (!yymsg)
  1055. yymsg = "Deleting";
  1056. YY_SYMBOL_PRINT(yymsg, yykind, yyvaluep, yylocationp);
  1057. YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN YY_USE(yykind);
  1058. YY_IGNORE_MAYBE_UNINITIALIZED_END}
  1059. /* Lookahead token kind. */
  1060. int yychar;
  1061. /* The semantic value of the lookahead symbol. */
  1062. YYSTYPE yylval;
  1063. /* Number of syntax errors so far. */
  1064. int yynerrs;
  1065. /*----------.
  1066. | yyparse. |
  1067. `----------*/
  1068. int yyparse(void)
  1069. {
  1070. yy_state_fast_t yystate = 0;
  1071. /* Number of tokens to shift before error messages enabled. */
  1072. int yyerrstatus = 0;
  1073. /* Refer to the stacks through separate pointers, to allow yyoverflow
  1074. to reallocate them elsewhere. */
  1075. /* Their size. */
  1076. YYPTRDIFF_T yystacksize = YYINITDEPTH;
  1077. /* The state stack: array, bottom, top. */
  1078. yy_state_t yyssa[YYINITDEPTH];
  1079. yy_state_t *yyss = yyssa;
  1080. yy_state_t *yyssp = yyss;
  1081. /* The semantic value stack: array, bottom, top. */
  1082. YYSTYPE yyvsa[YYINITDEPTH];
  1083. YYSTYPE *yyvs = yyvsa;
  1084. YYSTYPE *yyvsp = yyvs;
  1085. int yyn;
  1086. /* The return value of yyparse. */
  1087. int yyresult;
  1088. /* Lookahead symbol kind. */
  1089. yysymbol_kind_t yytoken = YYSYMBOL_YYEMPTY;
  1090. /* The variables used to return semantic value and location from the
  1091. action routines. */
  1092. YYSTYPE yyval;
  1093. #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))
  1094. /* The number of symbols on the RHS of the reduced rule.
  1095. Keep to zero when no symbol should be popped. */
  1096. int yylen = 0;
  1097. YYDPRINTF((stderr, "Starting parse\n"));
  1098. yychar = HLYEMPTY; /* Cause a token to be read. */
  1099. goto yysetstate;
  1100. /*------------------------------------------------------------.
  1101. | yynewstate -- push a new state, which is found in yystate. |
  1102. `------------------------------------------------------------*/
  1103. yynewstate:
  1104. /* In all cases, when you get here, the value and location stacks
  1105. have just been pushed. So pushing a state here evens the stacks. */
  1106. yyssp++;
  1107. /*--------------------------------------------------------------------.
  1108. | yysetstate -- set current state (the top of the stack) to yystate. |
  1109. `--------------------------------------------------------------------*/
  1110. yysetstate:
  1111. YYDPRINTF((stderr, "Entering state %d\n", yystate));
  1112. YY_ASSERT(0 <= yystate && yystate < YYNSTATES);
  1113. YY_IGNORE_USELESS_CAST_BEGIN *yyssp = YY_CAST(yy_state_t, yystate);
  1114. YY_IGNORE_USELESS_CAST_END YY_STACK_PRINT(yyss, yyssp);
  1115. if (yyss + yystacksize - 1 <= yyssp)
  1116. #if !defined yyoverflow && !defined YYSTACK_RELOCATE
  1117. goto yyexhaustedlab;
  1118. #else
  1119. {
  1120. /* Get the current used size of the three stacks, in elements. */
  1121. YYPTRDIFF_T yysize = yyssp - yyss + 1;
  1122. #if defined yyoverflow
  1123. {
  1124. /* Give user a chance to reallocate the stack. Use copies of
  1125. these so that the &'s don't force the real ones into
  1126. memory. */
  1127. yy_state_t *yyss1 = yyss;
  1128. YYSTYPE *yyvs1 = yyvs;
  1129. /* Each stack pointer address is followed by the size of the
  1130. data in use in that stack, in bytes. This used to be a
  1131. conditional around just the two extra args, but that might
  1132. be undefined if yyoverflow is a macro. */
  1133. yyoverflow(YY_("memory exhausted"), &yyss1, yysize * YYSIZEOF(*yyssp), &yyvs1, yysize * YYSIZEOF(*yyvsp), &yystacksize);
  1134. yyss = yyss1;
  1135. yyvs = yyvs1;
  1136. }
  1137. #else /* defined YYSTACK_RELOCATE */
  1138. /* Extend the stack our own way. */
  1139. if (YYMAXDEPTH <= yystacksize)
  1140. goto yyexhaustedlab;
  1141. yystacksize *= 2;
  1142. if (YYMAXDEPTH < yystacksize)
  1143. yystacksize = YYMAXDEPTH;
  1144. {
  1145. yy_state_t *yyss1 = yyss;
  1146. union yyalloc *yyptr = YY_CAST(union yyalloc *,
  1147. YYSTACK_ALLOC(YY_CAST(YYSIZE_T, YYSTACK_BYTES(yystacksize))));
  1148. if (!yyptr)
  1149. goto yyexhaustedlab;
  1150. YYSTACK_RELOCATE(yyss_alloc, yyss);
  1151. YYSTACK_RELOCATE(yyvs_alloc, yyvs);
  1152. #undef YYSTACK_RELOCATE
  1153. if (yyss1 != yyssa)
  1154. YYSTACK_FREE(yyss1);
  1155. }
  1156. #endif
  1157. yyssp = yyss + yysize - 1;
  1158. yyvsp = yyvs + yysize - 1;
  1159. YY_IGNORE_USELESS_CAST_BEGIN YYDPRINTF((stderr, "Stack size increased to %ld\n", YY_CAST(long, yystacksize)));
  1160. YY_IGNORE_USELESS_CAST_END if (yyss + yystacksize - 1 <= yyssp)
  1161. YYABORT;
  1162. }
  1163. #endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
  1164. if (yystate == YYFINAL)
  1165. YYACCEPT;
  1166. goto yybackup;
  1167. /*-----------.
  1168. | yybackup. |
  1169. `-----------*/
  1170. yybackup:
  1171. /* Do appropriate processing given the current state. Read a
  1172. lookahead token if we need one and don't already have one. */
  1173. /* First try to decide what to do without reference to lookahead token. */
  1174. yyn = yypact[yystate];
  1175. if (yypact_value_is_default(yyn))
  1176. goto yydefault;
  1177. /* Not known => get a lookahead token if don't already have one. */
  1178. /* YYCHAR is either empty, or end-of-input, or a valid lookahead. */
  1179. if (yychar == HLYEMPTY) {
  1180. YYDPRINTF((stderr, "Reading a token\n"));
  1181. yychar = yylex();
  1182. }
  1183. if (yychar <= HLYEOF) {
  1184. yychar = HLYEOF;
  1185. yytoken = YYSYMBOL_YYEOF;
  1186. YYDPRINTF((stderr, "Now at end of input.\n"));
  1187. } else if (yychar == HLYerror) {
  1188. /* The scanner already issued an error message, process directly
  1189. to error recovery. But do not keep the error token as
  1190. lookahead, it is too special and may lead us to an endless
  1191. loop in error recovery. */
  1192. yychar = HLYUNDEF;
  1193. yytoken = YYSYMBOL_YYerror;
  1194. goto yyerrlab1;
  1195. } else {
  1196. yytoken = YYTRANSLATE(yychar);
  1197. YY_SYMBOL_PRINT("Next token is", yytoken, &yylval, &yylloc);
  1198. }
  1199. /* If the proper action on seeing token YYTOKEN is to reduce or to
  1200. detect an error, take that action. */
  1201. yyn += yytoken;
  1202. if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
  1203. goto yydefault;
  1204. yyn = yytable[yyn];
  1205. if (yyn <= 0) {
  1206. if (yytable_value_is_error(yyn))
  1207. goto yyerrlab;
  1208. yyn = -yyn;
  1209. goto yyreduce;
  1210. }
  1211. /* Count tokens shifted since error; after three, turn off error
  1212. status. */
  1213. if (yyerrstatus)
  1214. yyerrstatus--;
  1215. /* Shift the lookahead token. */
  1216. YY_SYMBOL_PRINT("Shifting", yytoken, &yylval, &yylloc);
  1217. yystate = yyn;
  1218. YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN *++yyvsp = yylval;
  1219. YY_IGNORE_MAYBE_UNINITIALIZED_END
  1220. /* Discard the shifted token. */
  1221. yychar = HLYEMPTY;
  1222. goto yynewstate;
  1223. /*-----------------------------------------------------------.
  1224. | yydefault -- do the default action for the current state. |
  1225. `-----------------------------------------------------------*/
  1226. yydefault:
  1227. yyn = yydefact[yystate];
  1228. if (yyn == 0)
  1229. goto yyerrlab;
  1230. goto yyreduce;
  1231. /*-----------------------------.
  1232. | yyreduce -- do a reduction. |
  1233. `-----------------------------*/
  1234. yyreduce:
  1235. /* yyn is the number of a rule to reduce with. */
  1236. yylen = yyr2[yyn];
  1237. /* If YYLEN is nonzero, implement the default value of the action:
  1238. '$$ = $1'.
  1239. Otherwise, the following line sets YYVAL to garbage.
  1240. This behavior is undocumented and Bison
  1241. users should not rely upon it. Assigning to YYVAL
  1242. unconditionally makes the parser a bit smaller, and it avoids a
  1243. GCC warning that YYVAL may be used uninitialized. */
  1244. yyval = yyvsp[1 - yylen];
  1245. YY_REDUCE_PRINT(yyn);
  1246. switch (yyn) {
  1247. case 6: /* htmlparser2: fonttab2 */
  1248. #line 292 "dphl.y"
  1249. {
  1250. if (dphl_chk_err()) {
  1251. YYERROR;
  1252. }
  1253. }
  1254. #line 1500 "dphlparser.c"
  1255. break;
  1256. case 7: /* items: items item */
  1257. #line 297 "dphl.y"
  1258. {
  1259. if (dphl_chk_err()) {
  1260. YYERROR;
  1261. }
  1262. }
  1263. #line 1506 "dphlparser.c"
  1264. break;
  1265. case 8: /* items: item */
  1266. #line 298 "dphl.y"
  1267. {
  1268. if (dphl_chk_err()) {
  1269. YYERROR;
  1270. }
  1271. }
  1272. #line 1512 "dphlparser.c"
  1273. break;
  1274. case 9: /* item: "stringdata" */
  1275. #line 313 "dphl.y"
  1276. {
  1277. dphl_data((yyvsp[0].string));
  1278. }
  1279. #line 1518 "dphlparser.c"
  1280. break;
  1281. case 10: /* $@1: %empty */
  1282. #line 314 "dphl.y"
  1283. {
  1284. dphl_rbr();
  1285. }
  1286. #line 1524 "dphlparser.c"
  1287. break;
  1288. case 11: /* item: "<br" $@1 br_arg "/>" */
  1289. #line 314 "dphl.y"
  1290. {
  1291. dphl_ebr();
  1292. }
  1293. #line 1530 "dphlparser.c"
  1294. break;
  1295. case 12: /* $@2: %empty */
  1296. #line 315 "dphl.y"
  1297. {
  1298. dphl_rbr();
  1299. }
  1300. #line 1536 "dphlparser.c"
  1301. break;
  1302. case 13: /* item: "<br" ">" $@2 "</br" ">" */
  1303. #line 315 "dphl.y"
  1304. {
  1305. dphl_ebr();
  1306. }
  1307. #line 1542 "dphlparser.c"
  1308. break;
  1309. case 14: /* item: font items "</font" ">" */
  1310. #line 316 "dphl.y"
  1311. {
  1312. dphl_efont();
  1313. }
  1314. #line 1548 "dphlparser.c"
  1315. break;
  1316. case 15: /* item: italic items "</i" ">" */
  1317. #line 317 "dphl.y"
  1318. {
  1319. dphl_ei();
  1320. }
  1321. #line 1554 "dphlparser.c"
  1322. break;
  1323. case 16: /* item: bold items "</b" ">" */
  1324. #line 318 "dphl.y"
  1325. {
  1326. dphl_eb();
  1327. }
  1328. #line 1560 "dphlparser.c"
  1329. break;
  1330. case 17: /* item: underline items "</u" ">" */
  1331. #line 319 "dphl.y"
  1332. {
  1333. dphl_eu();
  1334. }
  1335. #line 1566 "dphlparser.c"
  1336. break;
  1337. case 18: /* item: overline items "</o" ">" */
  1338. #line 320 "dphl.y"
  1339. {
  1340. dphl_eo();
  1341. }
  1342. #line 1572 "dphlparser.c"
  1343. break;
  1344. case 19: /* $@3: %empty */
  1345. #line 321 "dphl.y"
  1346. {
  1347. dphl_rsub();
  1348. }
  1349. #line 1578 "dphlparser.c"
  1350. break;
  1351. case 20: /* item: "<sub" ">" $@3 items "</sub" ">" */
  1352. #line 321 "dphl.y"
  1353. {
  1354. dphl_esub();
  1355. }
  1356. #line 1584 "dphlparser.c"
  1357. break;
  1358. case 21: /* $@4: %empty */
  1359. #line 322 "dphl.y"
  1360. {
  1361. dphl_rsup();
  1362. }
  1363. #line 1590 "dphlparser.c"
  1364. break;
  1365. case 22: /* item: "<sup" ">" $@4 items "</sup" ">" */
  1366. #line 322 "dphl.y"
  1367. {
  1368. dphl_esup();
  1369. }
  1370. #line 1596 "dphlparser.c"
  1371. break;
  1372. case 23: /* $@5: %empty */
  1373. #line 323 "dphl.y"
  1374. {
  1375. dphl_rs();
  1376. }
  1377. #line 1602 "dphlparser.c"
  1378. break;
  1379. case 24: /* item: "<s" ">" $@5 items "</s" ">" */
  1380. #line 323 "dphl.y"
  1381. {
  1382. dphl_es();
  1383. }
  1384. #line 1608 "dphlparser.c"
  1385. break;
  1386. case 26: /* fonttab2: font tab "</font" ">" */
  1387. #line 338 "dphl.y"
  1388. {
  1389. dphl_efont();
  1390. }
  1391. #line 1614 "dphlparser.c"
  1392. break;
  1393. case 27: /* fonttab2: italic tab "</i" ">" */
  1394. #line 339 "dphl.y"
  1395. {
  1396. dphl_ei();
  1397. }
  1398. #line 1620 "dphlparser.c"
  1399. break;
  1400. case 28: /* fonttab2: bold tab "</b" ">" */
  1401. #line 340 "dphl.y"
  1402. {
  1403. dphl_eb();
  1404. }
  1405. #line 1626 "dphlparser.c"
  1406. break;
  1407. case 29: /* fonttab2: underline tab "</u" ">" */
  1408. #line 341 "dphl.y"
  1409. {
  1410. dphl_eu();
  1411. }
  1412. #line 1632 "dphlparser.c"
  1413. break;
  1414. case 30: /* fonttab2: overline tab "</o" ">" */
  1415. #line 342 "dphl.y"
  1416. {
  1417. dphl_eo();
  1418. }
  1419. #line 1638 "dphlparser.c"
  1420. break;
  1421. case 31: /* $@6: %empty */
  1422. #line 346 "dphl.y"
  1423. {
  1424. dphl_rfont();
  1425. }
  1426. #line 1644 "dphlparser.c"
  1427. break;
  1428. case 33: /* italic: "<i" ">" */
  1429. #line 350 "dphl.y"
  1430. {
  1431. dphl_ri();
  1432. }
  1433. #line 1650 "dphlparser.c"
  1434. break;
  1435. case 34: /* overline: "<o" ">" */
  1436. #line 354 "dphl.y"
  1437. {
  1438. dphl_ro();
  1439. }
  1440. #line 1656 "dphlparser.c"
  1441. break;
  1442. case 35: /* bold: "<b" ">" */
  1443. #line 358 "dphl.y"
  1444. {
  1445. dphl_rb();
  1446. }
  1447. #line 1662 "dphlparser.c"
  1448. break;
  1449. case 36: /* underline: "<u" ">" */
  1450. #line 362 "dphl.y"
  1451. {
  1452. dphl_ru();
  1453. }
  1454. #line 1668 "dphlparser.c"
  1455. break;
  1456. case 37: /* tabe: "stringdata" */
  1457. #line 367 "dphl.y"
  1458. {
  1459. dphl_tabledata((yyvsp[0].string));
  1460. }
  1461. #line 1674 "dphlparser.c"
  1462. break;
  1463. case 39: /* $@7: %empty */
  1464. #line 373 "dphl.y"
  1465. {
  1466. dphl_rtable();
  1467. }
  1468. #line 1680 "dphlparser.c"
  1469. break;
  1470. case 40: /* tab: tabe "<table" $@7 table_arg ">" rows "</table" ">" tabe */
  1471. #line 373 "dphl.y"
  1472. {
  1473. dphl_etable();
  1474. }
  1475. #line 1686 "dphlparser.c"
  1476. break;
  1477. case 43: /* $@8: %empty */
  1478. #line 380 "dphl.y"
  1479. {
  1480. dphl_rhr();
  1481. }
  1482. #line 1692 "dphlparser.c"
  1483. break;
  1484. case 45: /* $@9: %empty */
  1485. #line 381 "dphl.y"
  1486. {
  1487. dphl_rhr();
  1488. }
  1489. #line 1698 "dphlparser.c"
  1490. break;
  1491. case 47: /* $@10: %empty */
  1492. #line 386 "dphl.y"
  1493. {
  1494. dphl_rtr();
  1495. }
  1496. #line 1704 "dphlparser.c"
  1497. break;
  1498. case 48: /* row: "<tr" ">" $@10 cells "</tr" ">" */
  1499. #line 386 "dphl.y"
  1500. {
  1501. dphl_etr();
  1502. }
  1503. #line 1710 "dphlparser.c"
  1504. break;
  1505. case 51: /* $@11: %empty */
  1506. #line 393 "dphl.y"
  1507. {
  1508. dphl_rvr();
  1509. }
  1510. #line 1716 "dphlparser.c"
  1511. break;
  1512. case 53: /* $@12: %empty */
  1513. #line 394 "dphl.y"
  1514. {
  1515. dphl_rvr();
  1516. }
  1517. #line 1722 "dphlparser.c"
  1518. break;
  1519. case 55: /* cell: celltd td_arg ">" htmlparser "</td" ">" */
  1520. #line 402 "dphl.y"
  1521. {
  1522. dphl_etd(0);
  1523. }
  1524. #line 1728 "dphlparser.c"
  1525. break;
  1526. case 56: /* cell: celltd td_arg ">" cellimg img_arg "/>" "</td" ">" */
  1527. #line 403 "dphl.y"
  1528. {
  1529. dphl_eimg();
  1530. dphl_etd(1);
  1531. }
  1532. #line 1734 "dphlparser.c"
  1533. break;
  1534. case 57: /* cell: celltd td_arg ">" cellimg img_arg ">" "</img" ">" "</td" ">" */
  1535. #line 404 "dphl.y"
  1536. {
  1537. dphl_eimg();
  1538. dphl_etd(1);
  1539. }
  1540. #line 1740 "dphlparser.c"
  1541. break;
  1542. case 58: /* cell: celltd td_arg ">" "</td" ">" */
  1543. #line 405 "dphl.y"
  1544. {
  1545. dphl_etd(2);
  1546. }
  1547. #line 1746 "dphlparser.c"
  1548. break;
  1549. case 59: /* cellimg: "<img" */
  1550. #line 409 "dphl.y"
  1551. {
  1552. dphl_rimg();
  1553. }
  1554. #line 1752 "dphlparser.c"
  1555. break;
  1556. case 60: /* celltd: "<td" */
  1557. #line 413 "dphl.y"
  1558. {
  1559. dphl_rtd();
  1560. }
  1561. #line 1758 "dphlparser.c"
  1562. break;
  1563. case 63: /* table_1arg: "align" "=" "string" */
  1564. #line 445 "dphl.y"
  1565. {
  1566. if (dphl_chk_align((yyvsp[0].string), T_TABLE)) {
  1567. YYERROR;
  1568. }
  1569. }
  1570. #line 1764 "dphlparser.c"
  1571. break;
  1572. case 64: /* table_1arg: "bgcolor" "=" "string" */
  1573. #line 446 "dphl.y"
  1574. {
  1575. if (dphl_chk_bgcolor((yyvsp[0].string), T_TABLE)) {
  1576. YYERROR;
  1577. }
  1578. }
  1579. #line 1770 "dphlparser.c"
  1580. break;
  1581. case 65: /* table_1arg: "border" "=" "string" */
  1582. #line 447 "dphl.y"
  1583. {
  1584. if (dphl_chk_border((yyvsp[0].string), T_TABLE)) {
  1585. YYERROR;
  1586. }
  1587. }
  1588. #line 1776 "dphlparser.c"
  1589. break;
  1590. case 66: /* table_1arg: "cellborder" "=" "string" */
  1591. #line 448 "dphl.y"
  1592. {
  1593. if (dphl_chk_cellborder((yyvsp[0].string))) {
  1594. YYERROR;
  1595. }
  1596. }
  1597. #line 1782 "dphlparser.c"
  1598. break;
  1599. case 67: /* table_1arg: "cellpadding" "=" "string" */
  1600. #line 449 "dphl.y"
  1601. {
  1602. if (dphl_chk_cellpadding((yyvsp[0].string), T_TABLE)) {
  1603. YYERROR;
  1604. }
  1605. }
  1606. #line 1788 "dphlparser.c"
  1607. break;
  1608. case 68: /* table_1arg: "cellspacing" "=" "string" */
  1609. #line 450 "dphl.y"
  1610. {
  1611. if (dphl_chk_cellspacing((yyvsp[0].string), T_TABLE)) {
  1612. YYERROR;
  1613. }
  1614. }
  1615. #line 1794 "dphlparser.c"
  1616. break;
  1617. case 69: /* table_1arg: "color" "=" "string" */
  1618. #line 451 "dphl.y"
  1619. {
  1620. if (dphl_chk_color((yyvsp[0].string), T_TABLE)) {
  1621. YYERROR;
  1622. }
  1623. }
  1624. #line 1800 "dphlparser.c"
  1625. break;
  1626. case 70: /* table_1arg: "columns" "=" "string" */
  1627. #line 452 "dphl.y"
  1628. {
  1629. if (dphl_chk_columns((yyvsp[0].string))) {
  1630. YYERROR;
  1631. }
  1632. }
  1633. #line 1806 "dphlparser.c"
  1634. break;
  1635. case 71: /* table_1arg: "fixedsize" "=" "string" */
  1636. #line 453 "dphl.y"
  1637. {
  1638. if (dphl_chk_fixedsize((yyvsp[0].string), T_TABLE)) {
  1639. YYERROR;
  1640. }
  1641. }
  1642. #line 1812 "dphlparser.c"
  1643. break;
  1644. case 72: /* table_1arg: "gradientangle" "=" "string" */
  1645. #line 454 "dphl.y"
  1646. {
  1647. if (dphl_chk_gradientangle((yyvsp[0].string), T_TABLE)) {
  1648. YYERROR;
  1649. }
  1650. }
  1651. #line 1818 "dphlparser.c"
  1652. break;
  1653. case 73: /* table_1arg: "height" "=" "string" */
  1654. #line 455 "dphl.y"
  1655. {
  1656. if (dphl_chk_height((yyvsp[0].string), T_TABLE)) {
  1657. YYERROR;
  1658. }
  1659. }
  1660. #line 1824 "dphlparser.c"
  1661. break;
  1662. case 74: /* table_1arg: "href" "=" "string" */
  1663. #line 456 "dphl.y"
  1664. {
  1665. if (dphl_chk_href((yyvsp[0].string), T_TABLE)) {
  1666. YYERROR;
  1667. }
  1668. }
  1669. #line 1830 "dphlparser.c"
  1670. break;
  1671. case 75: /* table_1arg: "id" "=" "string" */
  1672. #line 457 "dphl.y"
  1673. {
  1674. if (dphl_chk_id((yyvsp[0].string), T_TABLE)) {
  1675. YYERROR;
  1676. }
  1677. }
  1678. #line 1836 "dphlparser.c"
  1679. break;
  1680. case 76: /* table_1arg: "port" "=" "string" */
  1681. #line 458 "dphl.y"
  1682. {
  1683. if (dphl_chk_port((yyvsp[0].string), T_TABLE)) {
  1684. YYERROR;
  1685. }
  1686. }
  1687. #line 1842 "dphlparser.c"
  1688. break;
  1689. case 77: /* table_1arg: "rows" "=" "string" */
  1690. #line 459 "dphl.y"
  1691. {
  1692. if (dphl_chk_rows((yyvsp[0].string))) {
  1693. YYERROR;
  1694. }
  1695. }
  1696. #line 1848 "dphlparser.c"
  1697. break;
  1698. case 78: /* table_1arg: "sides" "=" "string" */
  1699. #line 460 "dphl.y"
  1700. {
  1701. if (dphl_chk_sides((yyvsp[0].string), T_TABLE)) {
  1702. YYERROR;
  1703. }
  1704. }
  1705. #line 1854 "dphlparser.c"
  1706. break;
  1707. case 79: /* table_1arg: "style" "=" "string" */
  1708. #line 461 "dphl.y"
  1709. {
  1710. if (dphl_chk_style((yyvsp[0].string), T_TABLE)) {
  1711. YYERROR;
  1712. }
  1713. }
  1714. #line 1860 "dphlparser.c"
  1715. break;
  1716. case 80: /* table_1arg: "target" "=" "string" */
  1717. #line 462 "dphl.y"
  1718. {
  1719. if (dphl_chk_target((yyvsp[0].string), T_TABLE)) {
  1720. YYERROR;
  1721. }
  1722. }
  1723. #line 1866 "dphlparser.c"
  1724. break;
  1725. case 81: /* table_1arg: "title" "=" "string" */
  1726. #line 463 "dphl.y"
  1727. {
  1728. if (dphl_chk_title((yyvsp[0].string), T_TABLE)) {
  1729. YYERROR;
  1730. }
  1731. }
  1732. #line 1872 "dphlparser.c"
  1733. break;
  1734. case 82: /* table_1arg: "tooltip" "=" "string" */
  1735. #line 464 "dphl.y"
  1736. {
  1737. if (dphl_chk_title((yyvsp[0].string), T_TABLE)) {
  1738. YYERROR;
  1739. }
  1740. }
  1741. #line 1878 "dphlparser.c"
  1742. break;
  1743. case 83: /* table_1arg: "valign" "=" "string" */
  1744. #line 465 "dphl.y"
  1745. {
  1746. if (dphl_chk_valign((yyvsp[0].string), T_TABLE)) {
  1747. YYERROR;
  1748. }
  1749. }
  1750. #line 1884 "dphlparser.c"
  1751. break;
  1752. case 84: /* table_1arg: "width" "=" "string" */
  1753. #line 466 "dphl.y"
  1754. {
  1755. if (dphl_chk_width((yyvsp[0].string), T_TABLE)) {
  1756. YYERROR;
  1757. }
  1758. }
  1759. #line 1890 "dphlparser.c"
  1760. break;
  1761. case 85: /* table_1arg: "text" "=" "string" */
  1762. #line 467 "dphl.y"
  1763. {
  1764. dphl_attr_huh((char *)"<table>", (yyvsp[-2].string), (yyvsp[0].string));
  1765. }
  1766. #line 1896 "dphlparser.c"
  1767. break;
  1768. case 88: /* td_1arg: "align" "=" "string" */
  1769. #line 499 "dphl.y"
  1770. {
  1771. if (dphl_chk_align((yyvsp[0].string), T_TD)) {
  1772. YYERROR;
  1773. }
  1774. }
  1775. #line 1902 "dphlparser.c"
  1776. break;
  1777. case 89: /* td_1arg: "balign" "=" "string" */
  1778. #line 500 "dphl.y"
  1779. {
  1780. if (dphl_chk_balign((yyvsp[0].string))) {
  1781. YYERROR;
  1782. }
  1783. }
  1784. #line 1908 "dphlparser.c"
  1785. break;
  1786. case 90: /* td_1arg: "bgcolor" "=" "string" */
  1787. #line 501 "dphl.y"
  1788. {
  1789. if (dphl_chk_bgcolor((yyvsp[0].string), T_TD)) {
  1790. YYERROR;
  1791. }
  1792. }
  1793. #line 1914 "dphlparser.c"
  1794. break;
  1795. case 91: /* td_1arg: "border" "=" "string" */
  1796. #line 502 "dphl.y"
  1797. {
  1798. if (dphl_chk_border((yyvsp[0].string), T_TD)) {
  1799. YYERROR;
  1800. }
  1801. }
  1802. #line 1920 "dphlparser.c"
  1803. break;
  1804. case 92: /* td_1arg: "cellpadding" "=" "string" */
  1805. #line 503 "dphl.y"
  1806. {
  1807. if (dphl_chk_cellpadding((yyvsp[0].string), T_TD)) {
  1808. YYERROR;
  1809. }
  1810. }
  1811. #line 1926 "dphlparser.c"
  1812. break;
  1813. case 93: /* td_1arg: "cellspacing" "=" "string" */
  1814. #line 504 "dphl.y"
  1815. {
  1816. if (dphl_chk_cellspacing((yyvsp[0].string), T_TD)) {
  1817. YYERROR;
  1818. }
  1819. }
  1820. #line 1932 "dphlparser.c"
  1821. break;
  1822. case 94: /* td_1arg: "color" "=" "string" */
  1823. #line 505 "dphl.y"
  1824. {
  1825. if (dphl_chk_color((yyvsp[0].string), T_TD)) {
  1826. YYERROR;
  1827. }
  1828. }
  1829. #line 1938 "dphlparser.c"
  1830. break;
  1831. case 95: /* td_1arg: "colspan" "=" "string" */
  1832. #line 506 "dphl.y"
  1833. {
  1834. if (dphl_chk_colspan((yyvsp[0].string))) {
  1835. YYERROR;
  1836. }
  1837. }
  1838. #line 1944 "dphlparser.c"
  1839. break;
  1840. case 96: /* td_1arg: "fixedsize" "=" "string" */
  1841. #line 507 "dphl.y"
  1842. {
  1843. if (dphl_chk_fixedsize((yyvsp[0].string), T_TD)) {
  1844. YYERROR;
  1845. }
  1846. }
  1847. #line 1950 "dphlparser.c"
  1848. break;
  1849. case 97: /* td_1arg: "gradientangle" "=" "string" */
  1850. #line 508 "dphl.y"
  1851. {
  1852. if (dphl_chk_gradientangle((yyvsp[0].string), T_TD)) {
  1853. YYERROR;
  1854. }
  1855. }
  1856. #line 1956 "dphlparser.c"
  1857. break;
  1858. case 98: /* td_1arg: "height" "=" "string" */
  1859. #line 509 "dphl.y"
  1860. {
  1861. if (dphl_chk_height((yyvsp[0].string), T_TD)) {
  1862. YYERROR;
  1863. }
  1864. }
  1865. #line 1962 "dphlparser.c"
  1866. break;
  1867. case 99: /* td_1arg: "href" "=" "string" */
  1868. #line 510 "dphl.y"
  1869. {
  1870. if (dphl_chk_href((yyvsp[0].string), T_TD)) {
  1871. YYERROR;
  1872. }
  1873. }
  1874. #line 1968 "dphlparser.c"
  1875. break;
  1876. case 100: /* td_1arg: "id" "=" "string" */
  1877. #line 511 "dphl.y"
  1878. {
  1879. if (dphl_chk_id((yyvsp[0].string), T_TD)) {
  1880. YYERROR;
  1881. }
  1882. }
  1883. #line 1974 "dphlparser.c"
  1884. break;
  1885. case 101: /* td_1arg: "port" "=" "string" */
  1886. #line 512 "dphl.y"
  1887. {
  1888. if (dphl_chk_port((yyvsp[0].string), T_TD)) {
  1889. YYERROR;
  1890. }
  1891. }
  1892. #line 1980 "dphlparser.c"
  1893. break;
  1894. case 102: /* td_1arg: "rowspan" "=" "string" */
  1895. #line 513 "dphl.y"
  1896. {
  1897. if (dphl_chk_rowspan((yyvsp[0].string))) {
  1898. YYERROR;
  1899. }
  1900. }
  1901. #line 1986 "dphlparser.c"
  1902. break;
  1903. case 103: /* td_1arg: "sides" "=" "string" */
  1904. #line 514 "dphl.y"
  1905. {
  1906. if (dphl_chk_sides((yyvsp[0].string), T_TD)) {
  1907. YYERROR;
  1908. }
  1909. }
  1910. #line 1992 "dphlparser.c"
  1911. break;
  1912. case 104: /* td_1arg: "style" "=" "string" */
  1913. #line 515 "dphl.y"
  1914. {
  1915. if (dphl_chk_sides((yyvsp[0].string), T_TD)) {
  1916. YYERROR;
  1917. }
  1918. }
  1919. #line 1998 "dphlparser.c"
  1920. break;
  1921. case 105: /* td_1arg: "target" "=" "string" */
  1922. #line 516 "dphl.y"
  1923. {
  1924. if (dphl_chk_target((yyvsp[0].string), T_TD)) {
  1925. YYERROR;
  1926. }
  1927. }
  1928. #line 2004 "dphlparser.c"
  1929. break;
  1930. case 106: /* td_1arg: "title" "=" "string" */
  1931. #line 517 "dphl.y"
  1932. {
  1933. if (dphl_chk_title((yyvsp[0].string), T_TD)) {
  1934. YYERROR;
  1935. }
  1936. }
  1937. #line 2010 "dphlparser.c"
  1938. break;
  1939. case 107: /* td_1arg: "tooltip" "=" "string" */
  1940. #line 518 "dphl.y"
  1941. {
  1942. if (dphl_chk_title((yyvsp[0].string), T_TD)) {
  1943. YYERROR;
  1944. }
  1945. }
  1946. #line 2016 "dphlparser.c"
  1947. break;
  1948. case 108: /* td_1arg: "valign" "=" "string" */
  1949. #line 519 "dphl.y"
  1950. {
  1951. if (dphl_chk_valign((yyvsp[0].string), T_TD)) {
  1952. YYERROR;
  1953. }
  1954. }
  1955. #line 2022 "dphlparser.c"
  1956. break;
  1957. case 109: /* td_1arg: "width" "=" "string" */
  1958. #line 520 "dphl.y"
  1959. {
  1960. if (dphl_chk_width((yyvsp[0].string), T_TD)) {
  1961. YYERROR;
  1962. }
  1963. }
  1964. #line 2028 "dphlparser.c"
  1965. break;
  1966. case 110: /* td_1arg: "text" "=" "string" */
  1967. #line 521 "dphl.y"
  1968. {
  1969. dphl_attr_huh((char *)"<td>", (yyvsp[-2].string), (yyvsp[0].string));
  1970. }
  1971. #line 2034 "dphlparser.c"
  1972. break;
  1973. case 113: /* img_1arg: "scale" "=" "string" */
  1974. #line 535 "dphl.y"
  1975. {
  1976. if (dphl_chk_scale((yyvsp[0].string))) {
  1977. YYERROR;
  1978. }
  1979. }
  1980. #line 2040 "dphlparser.c"
  1981. break;
  1982. case 114: /* img_1arg: "src" "=" "string" */
  1983. #line 536 "dphl.y"
  1984. {
  1985. if (dphl_chk_src((yyvsp[0].string))) {
  1986. YYERROR;
  1987. }
  1988. }
  1989. #line 2046 "dphlparser.c"
  1990. break;
  1991. case 115: /* img_1arg: "text" "=" "string" */
  1992. #line 537 "dphl.y"
  1993. {
  1994. dphl_attr_huh((char *)"<img>", (yyvsp[-2].string), (yyvsp[0].string));
  1995. }
  1996. #line 2052 "dphlparser.c"
  1997. break;
  1998. case 118: /* br_1arg: "align" "=" "string" */
  1999. #line 549 "dphl.y"
  2000. {
  2001. if (dphl_chk_align((yyvsp[0].string), T_BR)) {
  2002. YYERROR;
  2003. }
  2004. }
  2005. #line 2058 "dphlparser.c"
  2006. break;
  2007. case 119: /* br_1arg: "text" "=" "string" */
  2008. #line 550 "dphl.y"
  2009. {
  2010. dphl_attr_huh((char *)"<br>", (yyvsp[-2].string), (yyvsp[0].string));
  2011. }
  2012. #line 2064 "dphlparser.c"
  2013. break;
  2014. case 122: /* font_1arg: "color" "=" "string" */
  2015. #line 564 "dphl.y"
  2016. {
  2017. if (dphl_chk_color((yyvsp[0].string), T_FONT)) {
  2018. YYERROR;
  2019. }
  2020. }
  2021. #line 2070 "dphlparser.c"
  2022. break;
  2023. case 123: /* font_1arg: "face" "=" "string" */
  2024. #line 565 "dphl.y"
  2025. {
  2026. if (dphl_chk_face((yyvsp[0].string))) {
  2027. YYERROR;
  2028. }
  2029. }
  2030. #line 2076 "dphlparser.c"
  2031. break;
  2032. case 124: /* font_1arg: "point-size" "=" "string" */
  2033. #line 566 "dphl.y"
  2034. {
  2035. if (dphl_chk_pointsize((yyvsp[0].string))) {
  2036. YYERROR;
  2037. }
  2038. }
  2039. #line 2082 "dphlparser.c"
  2040. break;
  2041. case 125: /* font_1arg: "text" "=" "string" */
  2042. #line 567 "dphl.y"
  2043. {
  2044. dphl_attr_huh((char *)"<font>", (yyvsp[-2].string), (yyvsp[0].string));
  2045. }
  2046. #line 2088 "dphlparser.c"
  2047. break;
  2048. #line 2092 "dphlparser.c"
  2049. default:
  2050. break;
  2051. }
  2052. /* User semantic actions sometimes alter yychar, and that requires
  2053. that yytoken be updated with the new translation. We take the
  2054. approach of translating immediately before every use of yytoken.
  2055. One alternative is translating here after every semantic action,
  2056. but that translation would be missed if the semantic action invokes
  2057. YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
  2058. if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
  2059. incorrect destructor might then be invoked immediately. In the
  2060. case of YYERROR or YYBACKUP, subsequent parser actions might lead
  2061. to an incorrect destructor call or verbose syntax error message
  2062. before the lookahead is translated. */
  2063. YY_SYMBOL_PRINT("-> $$ =", YY_CAST(yysymbol_kind_t, yyr1[yyn]), &yyval, &yyloc);
  2064. YYPOPSTACK(yylen);
  2065. yylen = 0;
  2066. *++yyvsp = yyval;
  2067. /* Now 'shift' the result of the reduction. Determine what state
  2068. that goes to, based on the state we popped back to and the rule
  2069. number reduced by. */
  2070. {
  2071. const int yylhs = yyr1[yyn] - YYNTOKENS;
  2072. const int yyi = yypgoto[yylhs] + *yyssp;
  2073. yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp ? yytable[yyi]
  2074. : yydefgoto[yylhs]);
  2075. }
  2076. goto yynewstate;
  2077. /*--------------------------------------.
  2078. | yyerrlab -- here on detecting error. |
  2079. `--------------------------------------*/
  2080. yyerrlab:
  2081. /* Make sure we have latest lookahead translation. See comments at
  2082. user semantic actions for why this is necessary. */
  2083. yytoken = yychar == HLYEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE(yychar);
  2084. /* If not already recovering from an error, report this error. */
  2085. if (!yyerrstatus) {
  2086. ++yynerrs;
  2087. yyerror(YY_("syntax error"));
  2088. }
  2089. if (yyerrstatus == 3) {
  2090. /* If just tried and failed to reuse lookahead token after an
  2091. error, discard it. */
  2092. if (yychar <= HLYEOF) {
  2093. /* Return failure if at end of input. */
  2094. if (yychar == HLYEOF)
  2095. YYABORT;
  2096. } else {
  2097. yydestruct("Error: discarding", yytoken, &yylval);
  2098. yychar = HLYEMPTY;
  2099. }
  2100. }
  2101. /* Else will try to reuse lookahead token after shifting the error
  2102. token. */
  2103. goto yyerrlab1;
  2104. /*---------------------------------------------------.
  2105. | yyerrorlab -- error raised explicitly by YYERROR. |
  2106. `---------------------------------------------------*/
  2107. yyerrorlab:
  2108. /* Pacify compilers when the user code never invokes YYERROR and the
  2109. label yyerrorlab therefore never appears in user code. */
  2110. if (0)
  2111. YYERROR;
  2112. /* Do not reclaim the symbols of the rule whose action triggered
  2113. this YYERROR. */
  2114. YYPOPSTACK(yylen);
  2115. yylen = 0;
  2116. YY_STACK_PRINT(yyss, yyssp);
  2117. yystate = *yyssp;
  2118. goto yyerrlab1;
  2119. /*-------------------------------------------------------------.
  2120. | yyerrlab1 -- common code for both syntax error and YYERROR. |
  2121. `-------------------------------------------------------------*/
  2122. yyerrlab1:
  2123. yyerrstatus = 3; /* Each real token shifted decrements this. */
  2124. /* Pop stack until we find a state that shifts the error token. */
  2125. for (;;) {
  2126. yyn = yypact[yystate];
  2127. if (!yypact_value_is_default(yyn)) {
  2128. yyn += YYSYMBOL_YYerror;
  2129. if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror) {
  2130. yyn = yytable[yyn];
  2131. if (0 < yyn)
  2132. break;
  2133. }
  2134. }
  2135. /* Pop the current state because it cannot handle the error token. */
  2136. if (yyssp == yyss)
  2137. YYABORT;
  2138. yydestruct("Error: popping", YY_ACCESSING_SYMBOL(yystate), yyvsp);
  2139. YYPOPSTACK(1);
  2140. yystate = *yyssp;
  2141. YY_STACK_PRINT(yyss, yyssp);
  2142. }
  2143. YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN *++yyvsp = yylval;
  2144. YY_IGNORE_MAYBE_UNINITIALIZED_END
  2145. /* Shift the error token. */
  2146. YY_SYMBOL_PRINT("Shifting", YY_ACCESSING_SYMBOL(yyn), yyvsp, yylsp);
  2147. yystate = yyn;
  2148. goto yynewstate;
  2149. /*-------------------------------------.
  2150. | yyacceptlab -- YYACCEPT comes here. |
  2151. `-------------------------------------*/
  2152. yyacceptlab:
  2153. yyresult = 0;
  2154. goto yyreturn;
  2155. /*-----------------------------------.
  2156. | yyabortlab -- YYABORT comes here. |
  2157. `-----------------------------------*/
  2158. yyabortlab:
  2159. yyresult = 1;
  2160. goto yyreturn;
  2161. #if !defined yyoverflow
  2162. /*-------------------------------------------------.
  2163. | yyexhaustedlab -- memory exhaustion comes here. |
  2164. `-------------------------------------------------*/
  2165. yyexhaustedlab:
  2166. yyerror(YY_("memory exhausted"));
  2167. yyresult = 2;
  2168. goto yyreturn;
  2169. #endif
  2170. /*-------------------------------------------------------.
  2171. | yyreturn -- parsing is finished, clean up and return. |
  2172. `-------------------------------------------------------*/
  2173. yyreturn:
  2174. if (yychar != HLYEMPTY) {
  2175. /* Make sure we have latest lookahead translation. See comments at
  2176. user semantic actions for why this is necessary. */
  2177. yytoken = YYTRANSLATE(yychar);
  2178. yydestruct("Cleanup: discarding lookahead", yytoken, &yylval);
  2179. }
  2180. /* Do not reclaim the symbols of the rule whose action triggered
  2181. this YYABORT or YYACCEPT. */
  2182. YYPOPSTACK(yylen);
  2183. YY_STACK_PRINT(yyss, yyssp);
  2184. while (yyssp != yyss) {
  2185. yydestruct("Cleanup: popping", YY_ACCESSING_SYMBOL(+*yyssp), yyvsp);
  2186. YYPOPSTACK(1);
  2187. }
  2188. #ifndef yyoverflow
  2189. if (yyss != yyssa)
  2190. YYSTACK_FREE(yyss);
  2191. #endif
  2192. return yyresult;
  2193. }
  2194. #line 570 "dphl.y"
  2195. /* end */