You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

smarty_internal_templateparser.php 153KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833
  1. <?php
  2. class TP_yyToken implements ArrayAccess
  3. {
  4. public $string = '';
  5. public $metadata = array();
  6. public function __construct($s, $m = array())
  7. {
  8. if ($s instanceof TP_yyToken) {
  9. $this->string = $s->string;
  10. $this->metadata = $s->metadata;
  11. } else {
  12. $this->string = (string) $s;
  13. if ($m instanceof TP_yyToken) {
  14. $this->metadata = $m->metadata;
  15. } elseif (is_array($m)) {
  16. $this->metadata = $m;
  17. }
  18. }
  19. }
  20. public function __toString()
  21. {
  22. return $this->string;
  23. }
  24. public function offsetExists($offset)
  25. {
  26. return isset($this->metadata[ $offset ]);
  27. }
  28. public function offsetGet($offset)
  29. {
  30. return $this->metadata[ $offset ];
  31. }
  32. public function offsetSet($offset, $value)
  33. {
  34. if ($offset === null) {
  35. if (isset($value[ 0 ])) {
  36. $x = ($value instanceof TP_yyToken) ? $value->metadata : $value;
  37. $this->metadata = array_merge($this->metadata, $x);
  38. return;
  39. }
  40. $offset = count($this->metadata);
  41. }
  42. if ($value === null) {
  43. return;
  44. }
  45. if ($value instanceof TP_yyToken) {
  46. if ($value->metadata) {
  47. $this->metadata[ $offset ] = $value->metadata;
  48. }
  49. } elseif ($value) {
  50. $this->metadata[ $offset ] = $value;
  51. }
  52. }
  53. public function offsetUnset($offset)
  54. {
  55. unset($this->metadata[ $offset ]);
  56. }
  57. }
  58. class TP_yyStackEntry
  59. {
  60. public $stateno; /* The state-number */
  61. public $major; /* The major token value. This is the code
  62. ** number for the token at this stack level */
  63. public $minor; /* The user-supplied minor token value. This
  64. ** is the value of the token */
  65. }
  66. ;
  67. #line 11 "../smarty/lexer/smarty_internal_templateparser.y"
  68. /**
  69. * Smarty Template Parser Class
  70. *
  71. * This is the template parser.
  72. * It is generated from the smarty_internal_templateparser.y file
  73. *
  74. * @author Uwe Tews <uwe.tews@googlemail.com>
  75. */
  76. class Smarty_Internal_Templateparser
  77. {
  78. #line 23 "../smarty/lexer/smarty_internal_templateparser.y"
  79. const Err1 = "Security error: Call to private object member not allowed";
  80. const Err2 = "Security error: Call to dynamic object member not allowed";
  81. const Err3 = "PHP in template not allowed. Use SmartyBC to enable it";
  82. /**
  83. * result status
  84. *
  85. * @var bool
  86. */
  87. public $successful = true;
  88. /**
  89. * return value
  90. *
  91. * @var mixed
  92. */
  93. public $retvalue = 0;
  94. /**
  95. * counter for prefix code
  96. *
  97. * @var int
  98. */
  99. public static $prefix_number = 0;
  100. /**
  101. * @var
  102. */
  103. public $yymajor;
  104. /**
  105. * last index of array variable
  106. *
  107. * @var mixed
  108. */
  109. public $last_index;
  110. /**
  111. * last variable name
  112. *
  113. * @var string
  114. */
  115. public $last_variable;
  116. /**
  117. * root parse tree buffer
  118. *
  119. * @var Smarty_Internal_ParseTree
  120. */
  121. public $root_buffer;
  122. /**
  123. * current parse tree object
  124. *
  125. * @var Smarty_Internal_ParseTree
  126. */
  127. public $current_buffer;
  128. /**
  129. * lexer object
  130. *
  131. * @var Smarty_Internal_Templatelexer
  132. */
  133. public $lex;
  134. /**
  135. * internal error flag
  136. *
  137. * @var bool
  138. */
  139. private $internalError = false;
  140. /**
  141. * {strip} status
  142. *
  143. * @var bool
  144. */
  145. public $strip = false;
  146. /**
  147. * compiler object
  148. *
  149. * @var Smarty_Internal_TemplateCompilerBase
  150. */
  151. public $compiler = null;
  152. /**
  153. * smarty object
  154. *
  155. * @var Smarty
  156. */
  157. public $smarty = null;
  158. /**
  159. * template object
  160. *
  161. * @var Smarty_Internal_Template
  162. */
  163. public $template = null;
  164. /**
  165. * block nesting level
  166. *
  167. * @var int
  168. */
  169. public $block_nesting_level = 0;
  170. /**
  171. * security object
  172. *
  173. * @var Smarty_Security
  174. */
  175. public $security = null;
  176. /**
  177. * template prefix array
  178. *
  179. * @var \Smarty_Internal_ParseTree[]
  180. */
  181. public $template_prefix = array();
  182. /**
  183. * security object
  184. *
  185. * @var \Smarty_Internal_ParseTree[]
  186. */
  187. public $template_postfix = array();
  188. /**
  189. * constructor
  190. *
  191. * @param Smarty_Internal_Templatelexer $lex
  192. * @param Smarty_Internal_TemplateCompilerBase $compiler
  193. */
  194. function __construct(Smarty_Internal_Templatelexer $lex, Smarty_Internal_TemplateCompilerBase $compiler)
  195. {
  196. $this->lex = $lex;
  197. $this->compiler = $compiler;
  198. $this->template = $this->compiler->template;
  199. $this->smarty = $this->template->smarty;
  200. $this->security = isset($this->smarty->security_policy) ? $this->smarty->security_policy : false;
  201. $this->current_buffer = $this->root_buffer = new Smarty_Internal_ParseTree_Template();
  202. }
  203. /**
  204. * insert PHP code in current buffer
  205. *
  206. * @param string $code
  207. */
  208. public function insertPhpCode($code)
  209. {
  210. $this->current_buffer->append_subtree($this, new Smarty_Internal_ParseTree_Tag($this, $code));
  211. }
  212. /**
  213. * merge PHP code with prefix code and return parse tree tag object
  214. *
  215. * @param string $code
  216. *
  217. * @return Smarty_Internal_ParseTree_Tag
  218. */
  219. public function mergePrefixCode($code)
  220. {
  221. $tmp = '';
  222. foreach ($this->compiler->prefix_code as $preCode) {
  223. $tmp .= $preCode;
  224. }
  225. $this->compiler->prefix_code = array();
  226. $tmp .= $code;
  227. return new Smarty_Internal_ParseTree_Tag($this, $this->compiler->processNocacheCode($tmp, true));
  228. }
  229. const TP_VERT = 1;
  230. const TP_COLON = 2;
  231. const TP_PHP = 3;
  232. const TP_NOCACHE = 4;
  233. const TP_TEXT = 5;
  234. const TP_STRIPON = 6;
  235. const TP_STRIPOFF = 7;
  236. const TP_LITERALSTART = 8;
  237. const TP_LITERALEND = 9;
  238. const TP_LITERAL = 10;
  239. const TP_RDEL = 11;
  240. const TP_SIMPELOUTPUT = 12;
  241. const TP_LDEL = 13;
  242. const TP_DOLLARID = 14;
  243. const TP_EQUAL = 15;
  244. const TP_SIMPLETAG = 16;
  245. const TP_ID = 17;
  246. const TP_PTR = 18;
  247. const TP_LDELIF = 19;
  248. const TP_LDELFOR = 20;
  249. const TP_SEMICOLON = 21;
  250. const TP_INCDEC = 22;
  251. const TP_TO = 23;
  252. const TP_STEP = 24;
  253. const TP_LDELFOREACH = 25;
  254. const TP_SPACE = 26;
  255. const TP_AS = 27;
  256. const TP_APTR = 28;
  257. const TP_LDELSETFILTER = 29;
  258. const TP_SMARTYBLOCKCHILDPARENT = 30;
  259. const TP_CLOSETAG = 31;
  260. const TP_LDELSLASH = 32;
  261. const TP_ATTR = 33;
  262. const TP_INTEGER = 34;
  263. const TP_COMMA = 35;
  264. const TP_OPENP = 36;
  265. const TP_CLOSEP = 37;
  266. const TP_MATH = 38;
  267. const TP_UNIMATH = 39;
  268. const TP_ISIN = 40;
  269. const TP_INSTANCEOF = 41;
  270. const TP_QMARK = 42;
  271. const TP_NOT = 43;
  272. const TP_TYPECAST = 44;
  273. const TP_HEX = 45;
  274. const TP_DOT = 46;
  275. const TP_SINGLEQUOTESTRING = 47;
  276. const TP_DOUBLECOLON = 48;
  277. const TP_NAMESPACE = 49;
  278. const TP_AT = 50;
  279. const TP_HATCH = 51;
  280. const TP_OPENB = 52;
  281. const TP_CLOSEB = 53;
  282. const TP_DOLLAR = 54;
  283. const TP_LOGOP = 55;
  284. const TP_TLOGOP = 56;
  285. const TP_SINGLECOND = 57;
  286. const TP_QUOTE = 58;
  287. const TP_BACKTICK = 59;
  288. const YY_NO_ACTION = 527;
  289. const YY_ACCEPT_ACTION = 526;
  290. const YY_ERROR_ACTION = 525;
  291. const YY_SZ_ACTTAB = 2021;
  292. static public $yy_action = array(242, 10, 131, 178, 255, 76, 157, 5, 83, 293, 12, 149, 152, 116, 292, 93, 331, 217,
  293. 284, 295, 221, 331, 226, 36, 21, 169, 35, 43, 308, 99, 26, 42, 39, 294, 235, 244,
  294. 30, 200, 187, 80, 1, 251, 320, 206, 442, 123, 53, 242, 10, 130, 98, 255, 194, 399,
  295. 5, 83, 442, 240, 298, 107, 116, 310, 174, 220, 217, 36, 295, 221, 399, 208, 135,
  296. 21, 26, 161, 43, 399, 8, 174, 42, 39, 294, 235, 218, 331, 200, 187, 80, 1, 312,
  297. 320, 11, 290, 313, 53, 242, 10, 133, 306, 255, 205, 187, 5, 83, 264, 266, 267, 211,
  298. 116, 353, 220, 52, 217, 298, 295, 221, 206, 226, 220, 21, 290, 290, 43, 321, 36,
  299. 249, 42, 39, 294, 235, 244, 26, 200, 206, 80, 1, 11, 320, 283, 52, 52, 53, 242, 10,
  300. 132, 248, 255, 205, 455, 5, 83, 84, 301, 151, 455, 116, 323, 92, 36, 217, 2, 295,
  301. 221, 331, 226, 26, 21, 290, 304, 43, 137, 36, 111, 42, 39, 294, 235, 244, 26, 200,
  302. 187, 80, 1, 225, 320, 320, 52, 123, 53, 242, 10, 133, 98, 255, 193, 175, 5, 83,
  303. 177, 280, 273, 234, 116, 310, 23, 278, 217, 13, 295, 221, 320, 203, 223, 21, 290,
  304. 442, 43, 138, 187, 326, 42, 39, 294, 235, 244, 216, 200, 442, 80, 1, 4, 320, 329,
  305. 52, 15, 53, 242, 10, 134, 91, 255, 205, 176, 5, 83, 293, 12, 16, 90, 116, 292, 300,
  306. 99, 217, 241, 295, 221, 320, 226, 215, 28, 213, 201, 43, 105, 187, 286, 42, 39,
  307. 294, 235, 244, 215, 200, 214, 80, 1, 105, 320, 11, 135, 285, 53, 242, 10, 133, 8,
  308. 255, 205, 164, 5, 83, 442, 215, 19, 239, 116, 99, 105, 331, 217, 6, 295, 221, 442,
  309. 192, 311, 21, 182, 289, 43, 308, 443, 32, 42, 39, 294, 235, 244, 296, 200, 17, 80,
  310. 1, 443, 320, 262, 107, 26, 53, 242, 10, 133, 122, 255, 191, 172, 5, 83, 183, 188,
  311. 148, 231, 116, 223, 168, 331, 217, 181, 295, 221, 331, 226, 206, 21, 331, 141, 43,
  312. 308, 206, 38, 42, 39, 294, 235, 244, 331, 200, 188, 80, 1, 187, 320, 155, 206, 308,
  313. 53, 242, 10, 133, 25, 255, 198, 188, 5, 83, 206, 145, 160, 308, 116, 228, 146, 206,
  314. 217, 180, 295, 221, 331, 226, 286, 21, 331, 359, 43, 179, 289, 38, 42, 39, 294,
  315. 235, 244, 250, 200, 271, 80, 1, 272, 320, 122, 94, 103, 53, 242, 10, 129, 3, 255,
  316. 205, 144, 5, 83, 185, 289, 170, 99, 116, 270, 322, 331, 217, 184, 295, 221, 331,
  317. 226, 99, 7, 171, 35, 43, 308, 89, 105, 42, 39, 294, 235, 244, 120, 200, 328, 80, 1,
  318. 187, 320, 82, 223, 4, 53, 242, 10, 134, 142, 255, 205, 107, 5, 83, 309, 324, 302,
  319. 20, 116, 316, 206, 291, 217, 290, 295, 221, 33, 226, 277, 28, 399, 243, 43, 257,
  320. 219, 189, 42, 39, 294, 235, 244, 110, 200, 140, 80, 399, 147, 320, 253, 327, 258,
  321. 53, 399, 14, 236, 220, 207, 154, 113, 65, 108, 319, 159, 238, 311, 98, 471, 471,
  322. 330, 237, 279, 471, 210, 325, 245, 299, 310, 86, 308, 143, 268, 263, 259, 260, 269,
  323. 177, 204, 287, 136, 242, 10, 150, 87, 255, 320, 139, 5, 83, 293, 12, 22, 195, 116,
  324. 292, 247, 258, 217, 153, 295, 221, 220, 207, 36, 126, 50, 104, 109, 112, 88, 26,
  325. 98, 246, 397, 330, 237, 85, 212, 210, 325, 245, 258, 310, 102, 299, 299, 220, 207,
  326. 397, 113, 65, 108, 320, 299, 134, 397, 98, 222, 442, 330, 237, 299, 299, 210, 325,
  327. 245, 258, 310, 299, 299, 442, 220, 207, 299, 126, 69, 108, 299, 288, 31, 299, 98,
  328. 299, 299, 330, 237, 299, 299, 210, 325, 245, 80, 310, 299, 320, 299, 258, 299, 299,
  329. 209, 299, 220, 207, 299, 126, 69, 108, 206, 299, 299, 455, 98, 299, 206, 330, 237,
  330. 455, 365, 210, 325, 245, 299, 310, 355, 227, 258, 299, 299, 299, 199, 220, 207, 36,
  331. 126, 64, 104, 299, 214, 36, 26, 98, 299, 442, 330, 237, 26, 299, 210, 325, 245,
  332. 258, 310, 471, 471, 442, 220, 207, 471, 126, 69, 108, 293, 12, 299, 299, 98, 292,
  333. 299, 330, 237, 299, 299, 210, 325, 245, 36, 310, 163, 299, 258, 299, 299, 26, 202,
  334. 220, 207, 299, 126, 44, 108, 471, 299, 299, 299, 98, 299, 299, 330, 237, 299, 299,
  335. 210, 325, 245, 299, 310, 299, 299, 258, 134, 299, 299, 252, 220, 207, 206, 126, 72,
  336. 108, 299, 299, 299, 299, 98, 299, 396, 330, 237, 299, 299, 210, 325, 245, 258, 310,
  337. 299, 299, 299, 220, 207, 396, 126, 74, 108, 254, 299, 80, 396, 98, 320, 299, 330,
  338. 237, 299, 297, 210, 325, 245, 299, 310, 299, 242, 9, 299, 299, 255, 299, 258, 5,
  339. 83, 299, 299, 220, 207, 116, 126, 68, 108, 217, 299, 295, 221, 98, 299, 299, 330,
  340. 237, 299, 299, 210, 325, 245, 299, 310, 299, 258, 299, 299, 299, 299, 220, 207,
  341. 299, 100, 70, 108, 299, 303, 29, 299, 98, 299, 299, 330, 237, 299, 297, 210, 325,
  342. 245, 299, 310, 299, 242, 9, 299, 299, 255, 299, 299, 5, 83, 299, 299, 299, 299,
  343. 116, 299, 299, 258, 217, 299, 295, 221, 220, 207, 299, 126, 66, 108, 299, 299, 299,
  344. 299, 98, 293, 12, 330, 237, 299, 292, 210, 325, 245, 299, 310, 258, 299, 299, 305,
  345. 29, 220, 207, 299, 126, 60, 108, 299, 293, 12, 299, 98, 299, 292, 330, 237, 299,
  346. 299, 210, 325, 245, 299, 310, 232, 299, 258, 299, 206, 299, 299, 220, 207, 299,
  347. 126, 49, 108, 299, 299, 299, 299, 98, 299, 299, 330, 237, 299, 230, 210, 325, 245,
  348. 299, 310, 258, 167, 299, 299, 299, 220, 207, 299, 126, 58, 108, 299, 41, 40, 37,
  349. 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 256, 275, 282,
  350. 220, 97, 299, 81, 45, 106, 299, 299, 299, 299, 98, 299, 299, 330, 237, 299, 299,
  351. 210, 325, 245, 299, 310, 299, 299, 258, 299, 206, 299, 299, 220, 207, 299, 126, 63,
  352. 108, 299, 186, 299, 299, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310,
  353. 258, 299, 299, 299, 299, 220, 197, 299, 114, 59, 108, 299, 41, 40, 37, 98, 299,
  354. 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 256, 275, 282, 220,
  355. 207, 299, 126, 55, 108, 299, 299, 299, 299, 98, 299, 299, 330, 237, 299, 299, 210,
  356. 325, 245, 299, 310, 299, 299, 258, 299, 206, 299, 299, 220, 207, 299, 126, 57, 108,
  357. 299, 41, 40, 37, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 258,
  358. 299, 256, 275, 282, 220, 95, 299, 81, 48, 106, 233, 41, 40, 37, 98, 299, 299, 330,
  359. 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 256, 275, 282, 220, 207, 299,
  360. 126, 78, 108, 299, 299, 299, 299, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245,
  361. 299, 310, 299, 299, 258, 299, 206, 18, 299, 220, 207, 299, 96, 61, 108, 299, 299,
  362. 299, 299, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 299,
  363. 299, 299, 220, 207, 299, 126, 47, 108, 299, 41, 40, 37, 98, 299, 299, 330, 237,
  364. 299, 299, 210, 325, 245, 299, 310, 258, 299, 256, 275, 282, 220, 207, 299, 126, 75,
  365. 108, 299, 299, 299, 299, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310,
  366. 299, 299, 258, 299, 206, 299, 299, 220, 207, 299, 126, 64, 108, 299, 299, 299, 299,
  367. 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 299, 299, 299,
  368. 220, 207, 299, 126, 56, 108, 317, 41, 40, 37, 98, 299, 299, 330, 237, 299, 299,
  369. 210, 325, 245, 299, 310, 258, 299, 256, 275, 282, 220, 207, 299, 115, 46, 108, 299,
  370. 299, 299, 299, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 299, 299,
  371. 258, 299, 206, 299, 299, 220, 207, 299, 126, 79, 108, 299, 190, 299, 299, 98, 299,
  372. 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 299, 299, 299, 220,
  373. 207, 299, 126, 62, 108, 299, 41, 40, 37, 98, 299, 299, 330, 237, 299, 299, 210,
  374. 325, 245, 299, 310, 258, 299, 256, 275, 282, 220, 207, 299, 126, 71, 108, 299, 299,
  375. 299, 299, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 299, 299, 258,
  376. 299, 206, 299, 299, 220, 207, 299, 101, 67, 108, 299, 318, 299, 299, 98, 299, 299,
  377. 330, 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 299, 299, 299, 220, 207,
  378. 299, 126, 77, 108, 299, 41, 40, 37, 98, 299, 299, 330, 237, 299, 299, 210, 325,
  379. 245, 299, 310, 258, 299, 256, 275, 282, 220, 196, 299, 126, 54, 108, 299, 299, 299,
  380. 299, 98, 299, 299, 330, 237, 299, 299, 210, 325, 245, 299, 310, 299, 299, 258, 299,
  381. 206, 299, 299, 220, 207, 299, 126, 73, 108, 299, 274, 299, 299, 98, 299, 299, 330,
  382. 237, 299, 299, 210, 325, 245, 299, 310, 258, 299, 299, 299, 299, 220, 224, 299,
  383. 118, 299, 108, 299, 41, 40, 37, 98, 299, 299, 299, 261, 299, 299, 210, 325, 245,
  384. 299, 310, 258, 299, 256, 275, 282, 220, 224, 299, 128, 299, 108, 299, 299, 299,
  385. 299, 98, 299, 299, 229, 315, 206, 299, 210, 325, 245, 299, 310, 299, 471, 471, 307,
  386. 27, 299, 471, 455, 526, 51, 265, 266, 267, 211, 299, 299, 220, 299, 36, 299, 409,
  387. 409, 299, 299, 299, 26, 299, 299, 299, 299, 41, 40, 37, 206, 299, 455, 299, 455,
  388. 299, 471, 299, 455, 299, 299, 299, 299, 299, 256, 275, 282, 229, 299, 299, 117,
  389. 299, 442, 299, 409, 409, 409, 471, 471, 299, 299, 299, 471, 455, 442, 299, 299, 41,
  390. 40, 37, 299, 409, 409, 409, 299, 299, 299, 299, 299, 299, 299, 299, 299, 299, 256,
  391. 275, 282, 299, 299, 299, 299, 455, 299, 455, 258, 471, 299, 455, 281, 220, 224,
  392. 299, 127, 299, 108, 299, 299, 299, 299, 98, 299, 299, 299, 299, 299, 299, 210, 325,
  393. 245, 258, 310, 206, 156, 299, 220, 224, 175, 121, 299, 108, 299, 299, 331, 299, 98,
  394. 23, 278, 299, 299, 299, 299, 210, 325, 245, 34, 310, 36, 299, 299, 187, 299, 299,
  395. 299, 26, 299, 299, 258, 299, 41, 40, 37, 220, 224, 299, 125, 299, 108, 299, 299,
  396. 299, 299, 98, 299, 299, 229, 256, 275, 282, 210, 325, 245, 299, 310, 299, 471, 471,
  397. 258, 31, 299, 471, 455, 220, 224, 299, 124, 299, 108, 299, 299, 299, 299, 98, 299,
  398. 299, 299, 299, 299, 299, 210, 325, 245, 258, 310, 206, 299, 299, 220, 224, 455,
  399. 119, 455, 108, 471, 299, 455, 299, 98, 299, 299, 229, 299, 299, 24, 210, 325, 245,
  400. 299, 310, 299, 471, 471, 299, 471, 471, 471, 455, 299, 471, 455, 206, 41, 40, 37,
  401. 299, 299, 299, 471, 471, 299, 299, 299, 471, 455, 299, 299, 276, 299, 256, 275,
  402. 282, 299, 299, 299, 455, 36, 455, 455, 471, 455, 455, 471, 26, 455, 299, 206, 403,
  403. 41, 40, 37, 206, 455, 299, 455, 299, 471, 403, 455, 403, 299, 299, 403, 299, 299,
  404. 256, 275, 282, 299, 403, 299, 403, 299, 403, 299, 299, 299, 299, 299, 299, 299,
  405. 299, 223, 41, 40, 37, 299, 299, 41, 40, 37, 299, 299, 299, 299, 299, 299, 299, 299,
  406. 173, 256, 275, 282, 175, 314, 256, 275, 282, 299, 331, 166, 299, 23, 278, 175, 162,
  407. 299, 299, 299, 175, 331, 299, 299, 23, 278, 331, 187, 299, 23, 278, 158, 299, 299,
  408. 299, 175, 299, 299, 187, 299, 299, 331, 165, 187, 23, 278, 175, 299, 299, 299, 299,
  409. 299, 331, 299, 299, 23, 278, 299, 187, 299, 299, 299, 299, 299, 299, 299, 299, 299,
  410. 299, 187,);
  411. static public $yy_lookahead = array(12, 13, 14, 80, 16, 17, 71, 19, 20, 12, 13, 71, 91, 25, 17, 75, 81, 29, 30, 31,
  412. 32, 81, 34, 26, 36, 28, 15, 39, 93, 18, 33, 43, 44, 45, 46, 47, 28, 49, 98, 51,
  413. 52, 70, 54, 1, 36, 74, 58, 12, 13, 14, 79, 16, 17, 11, 19, 20, 48, 86, 64, 48,
  414. 25, 90, 75, 69, 29, 26, 31, 32, 26, 34, 46, 36, 33, 71, 39, 33, 52, 75, 43, 44,
  415. 45, 46, 47, 81, 49, 98, 51, 52, 53, 54, 35, 22, 37, 58, 12, 13, 14, 103, 16, 17,
  416. 98, 19, 20, 63, 64, 65, 66, 25, 11, 69, 41, 29, 64, 31, 32, 1, 34, 69, 36, 22,
  417. 22, 39, 53, 26, 95, 43, 44, 45, 46, 47, 33, 49, 1, 51, 52, 35, 54, 37, 41, 41,
  418. 58, 12, 13, 14, 14, 16, 17, 46, 19, 20, 102, 103, 71, 52, 25, 11, 75, 26, 29,
  419. 36, 31, 32, 81, 34, 33, 36, 22, 17, 39, 14, 26, 48, 43, 44, 45, 46, 47, 33, 49,
  420. 98, 51, 52, 70, 54, 54, 41, 74, 58, 12, 13, 14, 79, 16, 17, 75, 19, 20, 8, 9,
  421. 10, 50, 25, 90, 84, 85, 29, 13, 31, 32, 54, 34, 46, 36, 22, 36, 39, 14, 98, 53,
  422. 43, 44, 45, 46, 47, 46, 49, 48, 51, 52, 36, 54, 53, 41, 21, 58, 12, 13, 14, 36,
  423. 16, 17, 75, 19, 20, 12, 13, 15, 35, 25, 17, 59, 18, 29, 22, 31, 32, 54, 34, 74,
  424. 36, 76, 77, 39, 79, 98, 99, 43, 44, 45, 46, 47, 74, 49, 76, 51, 52, 79, 54, 35,
  425. 46, 37, 58, 12, 13, 14, 52, 16, 17, 71, 19, 20, 36, 74, 15, 76, 25, 18, 79, 81,
  426. 29, 35, 31, 32, 48, 34, 92, 36, 94, 95, 39, 93, 36, 15, 43, 44, 45, 46, 47, 53,
  427. 49, 26, 51, 52, 48, 54, 89, 48, 33, 58, 12, 13, 14, 96, 16, 17, 71, 19, 20, 14,
  428. 98, 71, 17, 25, 46, 71, 81, 29, 75, 31, 32, 81, 34, 1, 36, 81, 71, 39, 93, 1, 2,
  429. 43, 44, 45, 46, 47, 81, 49, 98, 51, 52, 98, 54, 91, 1, 93, 58, 12, 13, 14, 28,
  430. 16, 17, 98, 19, 20, 1, 91, 71, 93, 25, 18, 71, 1, 29, 80, 31, 32, 81, 34, 99,
  431. 36, 81, 11, 39, 94, 95, 2, 43, 44, 45, 46, 47, 89, 49, 65, 51, 52, 68, 54, 96,
  432. 80, 79, 58, 12, 13, 14, 36, 16, 17, 71, 19, 20, 94, 95, 71, 18, 25, 53, 96, 81,
  433. 29, 75, 31, 32, 81, 34, 18, 36, 74, 15, 39, 93, 91, 79, 43, 44, 45, 46, 47, 17,
  434. 49, 17, 51, 52, 98, 54, 17, 46, 36, 58, 12, 13, 14, 51, 16, 17, 48, 19, 20, 17,
  435. 34, 17, 42, 25, 17, 1, 34, 29, 22, 31, 32, 23, 34, 37, 36, 11, 17, 39, 5, 17,
  436. 17, 43, 44, 45, 46, 47, 17, 49, 51, 51, 26, 27, 54, 11, 53, 64, 58, 33, 13, 14,
  437. 69, 70, 17, 72, 73, 74, 53, 91, 81, 92, 79, 12, 13, 82, 83, 9, 17, 86, 87, 88,
  438. 104, 90, 79, 93, 91, 3, 4, 5, 6, 7, 8, 100, 101, 79, 12, 13, 91, 79, 16, 54, 91,
  439. 19, 20, 12, 13, 13, 14, 25, 17, 17, 64, 29, 91, 31, 32, 69, 70, 26, 72, 73, 74,
  440. 78, 76, 79, 33, 79, 34, 11, 82, 83, 79, 15, 86, 87, 88, 64, 90, 67, 104, 104,
  441. 69, 70, 26, 72, 73, 74, 54, 104, 14, 33, 79, 17, 36, 82, 83, 104, 104, 86, 87,
  442. 88, 64, 90, 104, 104, 48, 69, 70, 104, 72, 73, 74, 104, 101, 15, 104, 79, 104,
  443. 104, 82, 83, 104, 104, 86, 87, 88, 51, 90, 104, 54, 104, 64, 104, 104, 97, 104,
  444. 69, 70, 104, 72, 73, 74, 1, 104, 104, 46, 79, 104, 1, 82, 83, 52, 11, 86, 87,
  445. 88, 104, 90, 11, 18, 64, 104, 104, 104, 97, 69, 70, 26, 72, 73, 74, 104, 76, 26,
  446. 33, 79, 104, 36, 82, 83, 33, 104, 86, 87, 88, 64, 90, 12, 13, 48, 69, 70, 17,
  447. 72, 73, 74, 12, 13, 104, 104, 79, 17, 104, 82, 83, 104, 104, 86, 87, 88, 26, 90,
  448. 28, 104, 64, 104, 104, 33, 97, 69, 70, 104, 72, 73, 74, 50, 104, 104, 104, 79,
  449. 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 104, 104, 64, 14, 104, 104, 17,
  450. 69, 70, 1, 72, 73, 74, 104, 104, 104, 104, 79, 104, 11, 82, 83, 104, 104, 86,
  451. 87, 88, 64, 90, 104, 104, 104, 69, 70, 26, 72, 73, 74, 49, 104, 51, 33, 79, 54,
  452. 104, 82, 83, 104, 5, 86, 87, 88, 104, 90, 104, 12, 13, 14, 104, 16, 104, 64, 19,
  453. 20, 104, 104, 69, 70, 25, 72, 73, 74, 29, 104, 31, 32, 79, 104, 104, 82, 83,
  454. 104, 104, 86, 87, 88, 104, 90, 104, 64, 104, 104, 104, 104, 69, 70, 104, 72, 73,
  455. 74, 104, 58, 59, 104, 79, 104, 104, 82, 83, 104, 5, 86, 87, 88, 104, 90, 104,
  456. 12, 13, 14, 104, 16, 104, 104, 19, 20, 104, 104, 104, 104, 25, 104, 104, 64, 29,
  457. 104, 31, 32, 69, 70, 104, 72, 73, 74, 104, 104, 104, 104, 79, 12, 13, 82, 83,
  458. 104, 17, 86, 87, 88, 104, 90, 64, 104, 104, 58, 59, 69, 70, 104, 72, 73, 74,
  459. 104, 12, 13, 104, 79, 104, 17, 82, 83, 104, 104, 86, 87, 88, 104, 90, 50, 104,
  460. 64, 104, 1, 104, 104, 69, 70, 104, 72, 73, 74, 104, 104, 104, 104, 79, 104, 104,
  461. 82, 83, 104, 50, 86, 87, 88, 104, 90, 64, 27, 104, 104, 104, 69, 70, 104, 72,
  462. 73, 74, 104, 38, 39, 40, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90,
  463. 64, 104, 55, 56, 57, 69, 70, 104, 72, 73, 74, 104, 104, 104, 104, 79, 104, 104,
  464. 82, 83, 104, 104, 86, 87, 88, 104, 90, 104, 104, 64, 104, 1, 104, 104, 69, 70,
  465. 104, 72, 73, 74, 104, 11, 104, 104, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88,
  466. 104, 90, 64, 104, 104, 104, 104, 69, 70, 104, 72, 73, 74, 104, 38, 39, 40, 79,
  467. 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 64, 104, 55, 56, 57, 69, 70,
  468. 104, 72, 73, 74, 104, 104, 104, 104, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88,
  469. 104, 90, 104, 104, 64, 104, 1, 104, 104, 69, 70, 104, 72, 73, 74, 104, 38, 39,
  470. 40, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 64, 104, 55, 56, 57,
  471. 69, 70, 104, 72, 73, 74, 37, 38, 39, 40, 79, 104, 104, 82, 83, 104, 104, 86, 87,
  472. 88, 104, 90, 64, 104, 55, 56, 57, 69, 70, 104, 72, 73, 74, 104, 104, 104, 104,
  473. 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 104, 104, 64, 104, 1, 2,
  474. 104, 69, 70, 104, 72, 73, 74, 104, 104, 104, 104, 79, 104, 104, 82, 83, 104,
  475. 104, 86, 87, 88, 104, 90, 64, 104, 104, 104, 104, 69, 70, 104, 72, 73, 74, 104,
  476. 38, 39, 40, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 64, 104, 55,
  477. 56, 57, 69, 70, 104, 72, 73, 74, 104, 104, 104, 104, 79, 104, 104, 82, 83, 104,
  478. 104, 86, 87, 88, 104, 90, 104, 104, 64, 104, 1, 104, 104, 69, 70, 104, 72, 73,
  479. 74, 104, 104, 104, 104, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 64,
  480. 104, 104, 104, 104, 69, 70, 104, 72, 73, 74, 37, 38, 39, 40, 79, 104, 104, 82,
  481. 83, 104, 104, 86, 87, 88, 104, 90, 64, 104, 55, 56, 57, 69, 70, 104, 72, 73, 74,
  482. 104, 104, 104, 104, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 104,
  483. 104, 64, 104, 1, 104, 104, 69, 70, 104, 72, 73, 74, 104, 11, 104, 104, 79, 104,
  484. 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 64, 104, 104, 104, 104, 69, 70, 104,
  485. 72, 73, 74, 104, 38, 39, 40, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104,
  486. 90, 64, 104, 55, 56, 57, 69, 70, 104, 72, 73, 74, 104, 104, 104, 104, 79, 104,
  487. 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 104, 104, 64, 104, 1, 104, 104, 69,
  488. 70, 104, 72, 73, 74, 104, 11, 104, 104, 79, 104, 104, 82, 83, 104, 104, 86, 87,
  489. 88, 104, 90, 64, 104, 104, 104, 104, 69, 70, 104, 72, 73, 74, 104, 38, 39, 40,
  490. 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 64, 104, 55, 56, 57, 69,
  491. 70, 104, 72, 73, 74, 104, 104, 104, 104, 79, 104, 104, 82, 83, 104, 104, 86, 87,
  492. 88, 104, 90, 104, 104, 64, 104, 1, 104, 104, 69, 70, 104, 72, 73, 74, 104, 11,
  493. 104, 104, 79, 104, 104, 82, 83, 104, 104, 86, 87, 88, 104, 90, 64, 104, 104,
  494. 104, 104, 69, 70, 104, 72, 104, 74, 104, 38, 39, 40, 79, 104, 104, 104, 83, 104,
  495. 104, 86, 87, 88, 104, 90, 64, 104, 55, 56, 57, 69, 70, 104, 72, 104, 74, 104,
  496. 104, 104, 104, 79, 104, 104, 2, 83, 1, 104, 86, 87, 88, 104, 90, 104, 12, 13,
  497. 11, 15, 104, 17, 18, 61, 62, 63, 64, 65, 66, 104, 104, 69, 104, 26, 104, 1, 2,
  498. 104, 104, 104, 33, 104, 104, 104, 104, 38, 39, 40, 1, 104, 46, 104, 48, 104, 50,
  499. 104, 52, 104, 104, 104, 104, 104, 55, 56, 57, 2, 104, 104, 21, 104, 36, 104, 38,
  500. 39, 40, 12, 13, 104, 104, 104, 17, 18, 48, 104, 104, 38, 39, 40, 104, 55, 56,
  501. 57, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 55, 56, 57, 104, 104, 104,
  502. 104, 46, 104, 48, 64, 50, 104, 52, 53, 69, 70, 104, 72, 104, 74, 104, 104, 104,
  503. 104, 79, 104, 104, 104, 104, 104, 104, 86, 87, 88, 64, 90, 1, 71, 104, 69, 70,
  504. 75, 72, 104, 74, 104, 104, 81, 104, 79, 84, 85, 104, 104, 104, 104, 86, 87, 88,
  505. 24, 90, 26, 104, 104, 98, 104, 104, 104, 33, 104, 104, 64, 104, 38, 39, 40, 69,
  506. 70, 104, 72, 104, 74, 104, 104, 104, 104, 79, 104, 104, 2, 55, 56, 57, 86, 87,
  507. 88, 104, 90, 104, 12, 13, 64, 15, 104, 17, 18, 69, 70, 104, 72, 104, 74, 104,
  508. 104, 104, 104, 79, 104, 104, 104, 104, 104, 104, 86, 87, 88, 64, 90, 1, 104,
  509. 104, 69, 70, 46, 72, 48, 74, 50, 104, 52, 104, 79, 104, 104, 2, 104, 104, 2, 86,
  510. 87, 88, 104, 90, 104, 12, 13, 104, 12, 13, 17, 18, 104, 17, 18, 1, 38, 39, 40,
  511. 104, 104, 104, 12, 13, 104, 104, 104, 17, 18, 104, 104, 53, 104, 55, 56, 57,
  512. 104, 104, 104, 46, 26, 48, 46, 50, 48, 52, 50, 33, 52, 104, 1, 11, 38, 39, 40,
  513. 1, 46, 104, 48, 104, 50, 21, 52, 23, 104, 104, 26, 104, 104, 55, 56, 57, 104,
  514. 33, 104, 35, 104, 37, 104, 104, 104, 104, 104, 104, 104, 104, 46, 38, 39, 40,
  515. 104, 104, 38, 39, 40, 104, 104, 104, 104, 104, 104, 104, 104, 71, 55, 56, 57,
  516. 75, 59, 55, 56, 57, 104, 81, 71, 104, 84, 85, 75, 71, 104, 104, 104, 75, 81,
  517. 104, 104, 84, 85, 81, 98, 104, 84, 85, 71, 104, 104, 104, 75, 104, 104, 98, 104,
  518. 104, 81, 71, 98, 84, 85, 75, 104, 104, 104, 104, 104, 81, 104, 104, 84, 85, 104,
  519. 98, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 98,);
  520. const YY_SHIFT_USE_DFLT = - 13;
  521. const YY_SHIFT_MAX = 236;
  522. static public $yy_shift_ofst = array(542, 364, 82, 82, 82, 411, 364, 411, 35, - 12, - 12, 82, 82, 82, 82, 82, 82,
  523. 176, 82, 82, 129, 82, 82, 82, 317, 82, 82, 82, 82, 82, 82, 270, 82, 82, 82, 82,
  524. 176, 223, 223, 458, 458, 458, 458, 458, 1734, 1603, 1862, 1862, 1862, 1862,
  525. 1862, 542, 749, 803, 1897, 1448, 1531, 1199, 1643, 1826, 1365, 950, 1282, 1033,
  526. 1116, 1902, 1902, 1902, 1902, 1902, 1902, 1902, 1902, 1902, 1902, 1902, 660,
  527. 1902, 1089, 1089, 594, 666, 131, 202, 865, - 3, 703, 551, 551, 233, 202, 202,
  528. 131, 131, 357, 97, 484, 144, 920, 505, 42, 768, 189, 232, 11, 232, 278, 324,
  529. 428, 39, 372, 324, 39, 351, 384, 391, 294, 155, 114, 114, 114, 114, 417, 417,
  530. 114, 114, 114, 114, - 13, 1786, 1659, 1600, 1844, 1841, 1858, 552, 897, 519,
  531. 618, 24, 101, 39, 101, 24, 39, 24, 39, 130, 39, 39, 24, 39, 24, 24, 193, 24,
  532. 39, 39, 39, 24, 39, 39, 39, 130, 39, 39, 39, 130, 39, 130, 39, 231, 39, 39,
  533. 114, 114, 114, 526, 404, 417, 404, 114, 417, 390, 114, 417, - 13, - 13, - 13,
  534. - 13, - 13, 1630, 1888, 576, 178, 694, 191, 69, 8, 100, 275, 212, 243, 297,
  535. 265, 255, 150, 98, 165, 55, 123, 493, 479, 468, 456, 434, 482, 483, 473, 461,
  536. 502, 489, 457, 452, 466, 422, 421, 449, 442, 444, 462, 432, 467, 440, 464, 446,
  537. 390,);
  538. const YY_REDUCE_USE_DFLT = - 80;
  539. const YY_REDUCE_MAX = 190;
  540. static public $yy_reduce_ofst = array(1558, 451, 556, 640, 586, 506, 531, 615, 995, 939, 1078, 723, 1244, 968, 856,
  541. 912, 1354, 1134, 1105, 1161, 1051, 1217, 1022, 1188, 1300, 1466, 1383, 1271,
  542. 1327, 1437, 1410, 757, 698, 669, 885, 829, 785, 1493, 1520, 1761, 1706, 1669,
  543. 1644, 1736, 1880, 1665, 1896, 1911, 1665, 1891, 1922, 40, - 29, 48, 119, 119,
  544. 119, 119, 119, 119, 119, 119, 119, 119, 119, 119, 119, 119, 119, 119, 119,
  545. 119, 119, 119, 119, 119, 81, 119, 119, 119, 112, 2, - 60, 184, - 6, 264, 358,
  546. - 65, 217, 213, 218, 197, 284, 269, 166, 363, - 13, 363, 295, 342, - 13, - 13,
  547. 349, 281, 310, 295, 310, 323, 310, 316, 272, 236, 273, - 13, - 13, - 13, 320,
  548. 374, - 13, - 13, 366, - 13, 338, 310, - 13, - 13, - 13, - 13, - 13, 465, 465,
  549. 465, 465, 465, 465, 474, 450, 465, 465, 437, 469, 447, 453, 437, 447, 437,
  550. 447, 463, 447, 447, 437, 447, 437, 437, 481, 437, 447, 447, 447, 437, 447,
  551. 447, 447, 478, 447, 447, 447, 511, 447, 504, 447, 503, 447, 447, 241, 241,
  552. 241, 530, 300, 29, 300, 241, 29, 361, 241, 29, - 79, - 77, 314, 340, 436,);
  553. static public $yyExpectedTokens = array(array(3, 4, 5, 6, 7, 8, 12, 13, 16, 19, 20, 25, 29, 31, 32,),
  554. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  555. 46, 47, 49, 51, 52, 54, 58,),
  556. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  557. 46, 47, 49, 51, 52, 54, 58,),
  558. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  559. 46, 47, 49, 51, 52, 54, 58,),
  560. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  561. 46, 47, 49, 51, 52, 54, 58,),
  562. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  563. 46, 47, 49, 51, 52, 54, 58,),
  564. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  565. 46, 47, 49, 51, 52, 54, 58,),
  566. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  567. 46, 47, 49, 51, 52, 54, 58,),
  568. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  569. 46, 47, 49, 51, 52, 53, 54, 58,),
  570. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 30, 31, 32, 34, 36, 39, 43, 44,
  571. 45, 46, 47, 49, 51, 52, 54, 58,),
  572. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 30, 31, 32, 34, 36, 39, 43, 44,
  573. 45, 46, 47, 49, 51, 52, 54, 58,),
  574. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  575. 46, 47, 49, 51, 52, 54, 58,),
  576. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  577. 46, 47, 49, 51, 52, 54, 58,),
  578. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  579. 46, 47, 49, 51, 52, 54, 58,),
  580. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  581. 46, 47, 49, 51, 52, 54, 58,),
  582. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  583. 46, 47, 49, 51, 52, 54, 58,),
  584. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  585. 46, 47, 49, 51, 52, 54, 58,),
  586. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  587. 46, 47, 49, 51, 52, 54, 58,),
  588. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  589. 46, 47, 49, 51, 52, 54, 58,),
  590. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  591. 46, 47, 49, 51, 52, 54, 58,),
  592. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  593. 46, 47, 49, 51, 52, 54, 58,),
  594. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  595. 46, 47, 49, 51, 52, 54, 58,),
  596. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  597. 46, 47, 49, 51, 52, 54, 58,),
  598. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  599. 46, 47, 49, 51, 52, 54, 58,),
  600. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  601. 46, 47, 49, 51, 52, 54, 58,),
  602. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  603. 46, 47, 49, 51, 52, 54, 58,),
  604. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  605. 46, 47, 49, 51, 52, 54, 58,),
  606. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  607. 46, 47, 49, 51, 52, 54, 58,),
  608. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  609. 46, 47, 49, 51, 52, 54, 58,),
  610. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  611. 46, 47, 49, 51, 52, 54, 58,),
  612. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  613. 46, 47, 49, 51, 52, 54, 58,),
  614. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  615. 46, 47, 49, 51, 52, 54, 58,),
  616. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  617. 46, 47, 49, 51, 52, 54, 58,),
  618. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  619. 46, 47, 49, 51, 52, 54, 58,),
  620. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  621. 46, 47, 49, 51, 52, 54, 58,),
  622. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  623. 46, 47, 49, 51, 52, 54, 58,),
  624. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  625. 46, 47, 49, 51, 52, 54, 58,),
  626. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  627. 46, 47, 49, 51, 52, 54, 58,),
  628. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  629. 46, 47, 49, 51, 52, 54, 58,),
  630. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  631. 46, 47, 49, 51, 54, 58,),
  632. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  633. 46, 47, 49, 51, 54, 58,),
  634. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  635. 46, 47, 49, 51, 54, 58,),
  636. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  637. 46, 47, 49, 51, 54, 58,),
  638. array(12, 13, 14, 16, 17, 19, 20, 25, 29, 31, 32, 34, 36, 39, 43, 44, 45,
  639. 46, 47, 49, 51, 54, 58,),
  640. array(1, 24, 26, 33, 38, 39, 40, 55, 56, 57,),
  641. array(1, 11, 26, 33, 38, 39, 40, 55, 56, 57,),
  642. array(1, 26, 33, 38, 39, 40, 55, 56, 57,),
  643. array(1, 26, 33, 38, 39, 40, 55, 56, 57,),
  644. array(1, 26, 33, 38, 39, 40, 55, 56, 57,),
  645. array(1, 26, 33, 38, 39, 40, 55, 56, 57,),
  646. array(1, 26, 33, 38, 39, 40, 55, 56, 57,),
  647. array(3, 4, 5, 6, 7, 8, 12, 13, 16, 19, 20, 25, 29, 31, 32,),
  648. array(14, 17, 49, 51, 54,),
  649. array(5, 12, 13, 14, 16, 19, 20, 25, 29, 31, 32, 58, 59,),
  650. array(1, 38, 39, 40, 55, 56, 57, 59,),
  651. array(1, 11, 38, 39, 40, 55, 56, 57,),
  652. array(1, 11, 38, 39, 40, 55, 56, 57,), array(1, 2, 38, 39, 40, 55, 56, 57,),
  653. array(1, 21, 38, 39, 40, 55, 56, 57,),
  654. array(1, 38, 39, 40, 53, 55, 56, 57,),
  655. array(1, 11, 38, 39, 40, 55, 56, 57,),
  656. array(1, 27, 38, 39, 40, 55, 56, 57,),
  657. array(1, 37, 38, 39, 40, 55, 56, 57,),
  658. array(1, 11, 38, 39, 40, 55, 56, 57,),
  659. array(1, 37, 38, 39, 40, 55, 56, 57,), array(1, 38, 39, 40, 55, 56, 57,),
  660. array(1, 38, 39, 40, 55, 56, 57,), array(1, 38, 39, 40, 55, 56, 57,),
  661. array(1, 38, 39, 40, 55, 56, 57,), array(1, 38, 39, 40, 55, 56, 57,),
  662. array(1, 38, 39, 40, 55, 56, 57,), array(1, 38, 39, 40, 55, 56, 57,),
  663. array(1, 38, 39, 40, 55, 56, 57,), array(1, 38, 39, 40, 55, 56, 57,),
  664. array(1, 38, 39, 40, 55, 56, 57,), array(1, 38, 39, 40, 55, 56, 57,),
  665. array(1, 11, 18, 26, 33, 36, 48,), array(1, 38, 39, 40, 55, 56, 57,),
  666. array(38, 39, 40, 55, 56, 57,), array(38, 39, 40, 55, 56, 57,),
  667. array(14, 17, 51, 54,), array(1, 11, 26, 33,), array(1, 26, 33,),
  668. array(14, 36, 54,),
  669. array(5, 12, 13, 14, 16, 19, 20, 25, 29, 31, 32, 58, 59,),
  670. array(12, 13, 17, 26, 28, 33,), array(12, 13, 17, 26, 28, 33,),
  671. array(12, 13, 17, 26, 33,), array(12, 13, 17, 26, 33,), array(18, 46, 52,),
  672. array(14, 36, 54,), array(14, 36, 54,), array(1, 26, 33,),
  673. array(1, 26, 33,), array(1, 2,), array(11, 22, 26, 33, 41,),
  674. array(1, 11, 26, 27, 33,), array(11, 22, 26, 33, 41,),
  675. array(12, 13, 17, 50,), array(13, 14, 17, 54,), array(1, 11, 26, 33,),
  676. array(1, 11, 26, 33,), array(8, 9, 10,), array(12, 13, 17,),
  677. array(15, 18, 48,), array(12, 13, 17,), array(15, 18, 48,), array(14, 17,),
  678. array(18, 48,), array(26, 33,), array(1, 18,), array(14, 17,),
  679. array(26, 33,), array(1, 28,), array(1, 53,), array(1, 11,), array(26, 33,),
  680. array(14, 54,), array(1,), array(1,), array(1,), array(1,), array(18,),
  681. array(18,), array(1,), array(1,), array(1,), array(1,), array(),
  682. array(2, 12, 13, 15, 17, 18, 46, 48, 50, 52,),
  683. array(2, 12, 13, 17, 18, 46, 48, 50, 52, 53,),
  684. array(2, 12, 13, 15, 17, 18, 46, 48, 50, 52,),
  685. array(2, 12, 13, 17, 18, 46, 48, 50, 52,),
  686. array(2, 12, 13, 17, 18, 46, 48, 50, 52,),
  687. array(12, 13, 17, 18, 46, 48, 50, 52,), array(13, 14, 17, 34, 54,),
  688. array(12, 13, 17, 50,), array(12, 13, 17,), array(15, 46, 52,),
  689. array(46, 52,), array(46, 52,), array(26, 33,), array(46, 52,),
  690. array(46, 52,), array(26, 33,), array(46, 52,), array(26, 33,),
  691. array(14, 54,), array(26, 33,), array(26, 33,), array(46, 52,),
  692. array(26, 33,), array(46, 52,), array(46, 52,), array(13, 36,),
  693. array(46, 52,), array(26, 33,), array(26, 33,), array(26, 33,),
  694. array(46, 52,), array(26, 33,), array(26, 33,), array(26, 33,),
  695. array(14, 54,), array(26, 33,), array(26, 33,), array(26, 33,),
  696. array(14, 54,), array(26, 33,), array(14, 54,), array(26, 33,),
  697. array(15, 22,), array(26, 33,), array(26, 33,), array(1,), array(1,),
  698. array(1,), array(9,), array(2,), array(18,), array(2,), array(1,),
  699. array(18,), array(36,), array(1,), array(18,), array(), array(), array(),
  700. array(), array(), array(1, 2, 36, 38, 39, 40, 48, 55, 56, 57,),
  701. array(11, 21, 23, 26, 33, 35, 37, 46,), array(11, 15, 26, 33, 36, 48,),
  702. array(36, 46, 48, 53,), array(12, 13, 17, 50,), array(22, 41, 59,),
  703. array(22, 41, 53,), array(28, 36, 48,), array(35, 37,), array(36, 48,),
  704. array(21, 35,), array(35, 37,), array(15, 46,), array(35, 53,),
  705. array(36, 48,), array(17, 50,), array(22, 41,), array(46, 53,),
  706. array(35, 37,), array(36, 48,), array(5,), array(17,), array(23,),
  707. array(37,), array(15,), array(17,), array(17,), array(53,), array(53,),
  708. array(11,), array(17,), array(51,), array(34,), array(22,), array(51,),
  709. array(46,), array(17,), array(17,), array(17,), array(17,), array(36,),
  710. array(17,), array(42,), array(17,), array(34,), array(36,), array(),
  711. array(), array(), array(), array(), array(), array(), array(), array(),
  712. array(), array(), array(), array(), array(), array(), array(), array(),
  713. array(), array(), array(), array(), array(), array(), array(), array(),
  714. array(), array(), array(), array(), array(), array(), array(), array(),
  715. array(), array(), array(), array(), array(), array(), array(), array(),
  716. array(), array(), array(), array(), array(), array(), array(), array(),
  717. array(), array(), array(), array(), array(), array(), array(), array(),
  718. array(), array(), array(), array(), array(), array(), array(), array(),
  719. array(), array(), array(), array(), array(), array(), array(), array(),
  720. array(), array(), array(), array(), array(), array(), array(), array(),
  721. array(), array(), array(), array(), array(), array(), array(), array(),
  722. array(), array(), array(), array(), array(), array(),);
  723. static public $yy_default = array(335, 510, 490, 490, 490, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525,
  724. 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525,
  725. 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 393, 525, 360, 393,
  726. 357, 393, 369, 332, 525, 525, 525, 525, 525, 525, 525, 525, 525, 398, 525, 525,
  727. 525, 513, 405, 395, 404, 489, 398, 374, 400, 511, 488, 414, 432, 512, 421, 420,
  728. 525, 407, 393, 525, 525, 393, 393, 393, 393, 502, 525, 525, 393, 393, 383, 422,
  729. 407, 422, 455, 525, 407, 407, 525, 455, 445, 455, 445, 525, 445, 393, 387, 525,
  730. 371, 407, 407, 407, 393, 525, 417, 425, 389, 410, 499, 445, 423, 411, 407, 424,
  731. 497, 444, 444, 444, 444, 444, 444, 525, 457, 455, 471, 449, 448, 366, 450, 451,
  732. 379, 453, 378, 525, 368, 367, 452, 364, 483, 480, 455, 481, 358, 380, 362, 482,
  733. 373, 356, 361, 525, 382, 370, 377, 525, 372, 525, 354, 525, 381, 376, 439, 413,
  734. 384, 348, 492, 477, 491, 388, 503, 455, 390, 500, 455, 496, 496, 496, 455, 432,
  735. 428, 432, 432, 456, 422, 422, 432, 525, 440, 525, 525, 428, 525, 432, 525, 422,
  736. 428, 525, 525, 340, 525, 401, 525, 525, 525, 525, 435, 525, 525, 525, 525, 430,
  737. 422, 525, 428, 525, 525, 525, 525, 501, 525, 434, 525, 525, 471, 412, 391, 402,
  738. 418, 375, 352, 394, 435, 436, 460, 459, 471, 479, 437, 419, 442, 351, 443, 363,
  739. 504, 342, 438, 341, 343, 416, 441, 339, 334, 333, 336, 337, 338, 344, 468, 349,
  740. 347, 350, 476, 505, 469, 406, 415, 345, 346, 466, 506, 486, 385, 487, 495, 508,
  741. 509, 478, 426, 429, 474, 475, 427, 386, 507, 524, 523, 520, 518, 517, 493, 514,
  742. 494, 515, 516, 522, 473, 446, 447, 454, 470, 485, 519, 498, 458, 434, 461, 464,
  743. 472, 467, 484, 521, 431, 433, 465, 463, 409, 462, 408, 392,);
  744. const YYNOCODE = 105;
  745. const YYSTACKDEPTH = 500;
  746. const YYNSTATE = 332;
  747. const YYNRULE = 193;
  748. const YYERRORSYMBOL = 60;
  749. const YYERRSYMDT = 'yy0';
  750. const YYFALLBACK = 0;
  751. public static $yyFallback = array();
  752. public function Trace($TraceFILE, $zTracePrompt)
  753. {
  754. if (!$TraceFILE) {
  755. $zTracePrompt = 0;
  756. } elseif (!$zTracePrompt) {
  757. $TraceFILE = 0;
  758. }
  759. $this->yyTraceFILE = $TraceFILE;
  760. $this->yyTracePrompt = $zTracePrompt;
  761. }
  762. public function PrintTrace()
  763. {
  764. $this->yyTraceFILE = fopen('php://output', 'w');
  765. $this->yyTracePrompt = '<br>';
  766. }
  767. public $yyTraceFILE;
  768. public $yyTracePrompt;
  769. public $yyidx; /* Index of top element in stack */
  770. public $yyerrcnt; /* Shifts left before out of the error */
  771. public $yystack = array(); /* The parser's stack */
  772. public $yyTokenName = array('$', 'VERT', 'COLON', 'PHP', 'NOCACHE', 'TEXT', 'STRIPON', 'STRIPOFF', 'LITERALSTART',
  773. 'LITERALEND', 'LITERAL', 'RDEL', 'SIMPELOUTPUT', 'LDEL', 'DOLLARID', 'EQUAL',
  774. 'SIMPLETAG', 'ID', 'PTR', 'LDELIF', 'LDELFOR', 'SEMICOLON', 'INCDEC', 'TO', 'STEP',
  775. 'LDELFOREACH', 'SPACE', 'AS', 'APTR', 'LDELSETFILTER', 'SMARTYBLOCKCHILDPARENT',
  776. 'CLOSETAG', 'LDELSLASH', 'ATTR', 'INTEGER', 'COMMA', 'OPENP', 'CLOSEP', 'MATH',
  777. 'UNIMATH', 'ISIN', 'INSTANCEOF', 'QMARK', 'NOT', 'TYPECAST', 'HEX', 'DOT',
  778. 'SINGLEQUOTESTRING', 'DOUBLECOLON', 'NAMESPACE', 'AT', 'HATCH', 'OPENB', 'CLOSEB',
  779. 'DOLLAR', 'LOGOP', 'TLOGOP', 'SINGLECOND', 'QUOTE', 'BACKTICK', 'error', 'start',
  780. 'template', 'template_element', 'smartytag', 'literal', 'text_content',
  781. 'literal_elements', 'literal_element', 'tag', 'variable', 'attributes', 'value', 'expr',
  782. 'varindexed', 'modifierlist', 'statement', 'statements', 'foraction', 'varvar',
  783. 'modparameters', 'attribute', 'ternary', 'array', 'lop', 'scond', 'ns1', 'function',
  784. 'doublequoted_with_quotes', 'static_class_access', 'object', 'arrayindex', 'indexdef',
  785. 'varvarele', 'objectchain', 'objectelement', 'method', 'params', 'modifier',
  786. 'modparameter', 'arrayelements', 'arrayelement', 'doublequoted',
  787. 'doublequotedcontent',);
  788. public static $yyRuleName = array('start ::= template', 'template ::= template_element',
  789. 'template ::= template template_element', 'template ::=',
  790. 'template_element ::= smartytag', 'template_element ::= literal',
  791. 'template_element ::= PHP', 'template_element ::= NOCACHE',
  792. 'template_element ::= text_content', 'text_content ::= TEXT',
  793. 'text_content ::= text_content TEXT', 'template_element ::= STRIPON',
  794. 'template_element ::= STRIPOFF', 'literal ::= LITERALSTART LITERALEND',
  795. 'literal ::= LITERALSTART literal_elements LITERALEND',
  796. 'literal_elements ::= literal_elements literal_element', 'literal_elements ::=',
  797. 'literal_element ::= literal', 'literal_element ::= LITERAL',
  798. 'smartytag ::= tag RDEL', 'smartytag ::= SIMPELOUTPUT', 'tag ::= LDEL variable',
  799. 'tag ::= LDEL variable attributes', 'tag ::= LDEL value',
  800. 'tag ::= LDEL value attributes', 'tag ::= LDEL expr',
  801. 'tag ::= LDEL expr attributes', 'tag ::= LDEL DOLLARID EQUAL value',
  802. 'tag ::= LDEL DOLLARID EQUAL expr', 'tag ::= LDEL DOLLARID EQUAL expr attributes',
  803. 'tag ::= LDEL varindexed EQUAL expr attributes', 'smartytag ::= SIMPLETAG',
  804. 'tag ::= LDEL ID attributes', 'tag ::= LDEL ID',
  805. 'tag ::= LDEL ID modifierlist attributes', 'tag ::= LDEL ID PTR ID attributes',
  806. 'tag ::= LDEL ID PTR ID modifierlist attributes', 'tag ::= LDELIF expr',
  807. 'tag ::= LDELIF expr attributes', 'tag ::= LDELIF statement',
  808. 'tag ::= LDELIF statement attributes',
  809. 'tag ::= LDELFOR statements SEMICOLON expr SEMICOLON varindexed foraction attributes',
  810. 'foraction ::= EQUAL expr', 'foraction ::= INCDEC',
  811. 'tag ::= LDELFOR statement TO expr attributes',
  812. 'tag ::= LDELFOR statement TO expr STEP expr attributes',
  813. 'tag ::= LDELFOREACH attributes',
  814. 'tag ::= LDELFOREACH SPACE value AS varvar attributes',
  815. 'tag ::= LDELFOREACH SPACE value AS varvar APTR varvar attributes',
  816. 'tag ::= LDELFOREACH SPACE expr AS varvar attributes',
  817. 'tag ::= LDELFOREACH SPACE expr AS varvar APTR varvar attributes',
  818. 'tag ::= LDELSETFILTER ID modparameters',
  819. 'tag ::= LDELSETFILTER ID modparameters modifierlist',
  820. 'tag ::= LDEL SMARTYBLOCKCHILDPARENT', 'smartytag ::= CLOSETAG',
  821. 'tag ::= LDELSLASH ID', 'tag ::= LDELSLASH ID modifierlist',
  822. 'tag ::= LDELSLASH ID PTR ID', 'tag ::= LDELSLASH ID PTR ID modifierlist',
  823. 'attributes ::= attributes attribute', 'attributes ::= attribute',
  824. 'attributes ::=', 'attribute ::= SPACE ID EQUAL ID', 'attribute ::= ATTR expr',
  825. 'attribute ::= ATTR value', 'attribute ::= SPACE ID', 'attribute ::= SPACE expr',
  826. 'attribute ::= SPACE value', 'attribute ::= SPACE INTEGER EQUAL expr',
  827. 'statements ::= statement', 'statements ::= statements COMMA statement',
  828. 'statement ::= DOLLARID EQUAL INTEGER', 'statement ::= DOLLARID EQUAL expr',
  829. 'statement ::= varindexed EQUAL expr', 'statement ::= OPENP statement CLOSEP',
  830. 'expr ::= value', 'expr ::= ternary', 'expr ::= DOLLARID COLON ID',
  831. 'expr ::= expr MATH value', 'expr ::= expr UNIMATH value', 'expr ::= array',
  832. 'expr ::= expr modifierlist', 'expr ::= expr lop expr', 'expr ::= expr scond',
  833. 'expr ::= expr ISIN array', 'expr ::= expr ISIN value',
  834. 'expr ::= variable INSTANCEOF ns1', 'expr ::= variable INSTANCEOF variable',
  835. 'ternary ::= OPENP expr CLOSEP QMARK DOLLARID COLON expr',
  836. 'ternary ::= OPENP expr CLOSEP QMARK expr COLON expr', 'value ::= variable',
  837. 'value ::= UNIMATH value', 'value ::= NOT value', 'value ::= TYPECAST value',
  838. 'value ::= variable INCDEC', 'value ::= HEX', 'value ::= INTEGER',
  839. 'value ::= INTEGER DOT INTEGER', 'value ::= INTEGER DOT', 'value ::= DOT INTEGER',
  840. 'value ::= ID', 'value ::= function', 'value ::= OPENP expr CLOSEP',
  841. 'value ::= SINGLEQUOTESTRING', 'value ::= doublequoted_with_quotes',
  842. 'value ::= varindexed DOUBLECOLON static_class_access', 'value ::= smartytag',
  843. 'value ::= value modifierlist', 'value ::= NAMESPACE',
  844. 'value ::= ns1 DOUBLECOLON static_class_access', 'ns1 ::= ID',
  845. 'ns1 ::= NAMESPACE', 'variable ::= DOLLARID', 'variable ::= varindexed',
  846. 'variable ::= varvar AT ID', 'variable ::= object', 'variable ::= HATCH ID HATCH',
  847. 'variable ::= HATCH ID HATCH arrayindex', 'variable ::= HATCH variable HATCH',
  848. 'variable ::= HATCH variable HATCH arrayindex',
  849. 'varindexed ::= DOLLARID arrayindex', 'varindexed ::= varvar arrayindex',
  850. 'arrayindex ::= arrayindex indexdef', 'arrayindex ::=',
  851. 'indexdef ::= DOT DOLLARID', 'indexdef ::= DOT varvar',
  852. 'indexdef ::= DOT varvar AT ID', 'indexdef ::= DOT ID',
  853. 'indexdef ::= DOT INTEGER', 'indexdef ::= DOT LDEL expr RDEL',
  854. 'indexdef ::= OPENB ID CLOSEB', 'indexdef ::= OPENB ID DOT ID CLOSEB',
  855. 'indexdef ::= OPENB SINGLEQUOTESTRING CLOSEB',
  856. 'indexdef ::= OPENB INTEGER CLOSEB', 'indexdef ::= OPENB DOLLARID CLOSEB',
  857. 'indexdef ::= OPENB variable CLOSEB', 'indexdef ::= OPENB value CLOSEB',
  858. 'indexdef ::= OPENB expr CLOSEB', 'indexdef ::= OPENB CLOSEB',
  859. 'varvar ::= DOLLARID', 'varvar ::= DOLLAR', 'varvar ::= varvar varvarele',
  860. 'varvarele ::= ID', 'varvarele ::= SIMPELOUTPUT', 'varvarele ::= LDEL expr RDEL',
  861. 'object ::= varindexed objectchain', 'objectchain ::= objectelement',
  862. 'objectchain ::= objectchain objectelement',
  863. 'objectelement ::= PTR ID arrayindex', 'objectelement ::= PTR varvar arrayindex',
  864. 'objectelement ::= PTR LDEL expr RDEL arrayindex',
  865. 'objectelement ::= PTR ID LDEL expr RDEL arrayindex',
  866. 'objectelement ::= PTR method', 'function ::= ns1 OPENP params CLOSEP',
  867. 'method ::= ID OPENP params CLOSEP', 'method ::= DOLLARID OPENP params CLOSEP',
  868. 'params ::= params COMMA expr', 'params ::= expr', 'params ::=',
  869. 'modifierlist ::= modifierlist modifier modparameters',
  870. 'modifierlist ::= modifier modparameters', 'modifier ::= VERT AT ID',
  871. 'modifier ::= VERT ID', 'modparameters ::= modparameters modparameter',
  872. 'modparameters ::=', 'modparameter ::= COLON value',
  873. 'modparameter ::= COLON array', 'static_class_access ::= method',
  874. 'static_class_access ::= method objectchain', 'static_class_access ::= ID',
  875. 'static_class_access ::= DOLLARID arrayindex',
  876. 'static_class_access ::= DOLLARID arrayindex objectchain', 'lop ::= LOGOP',
  877. 'lop ::= TLOGOP', 'scond ::= SINGLECOND', 'array ::= OPENB arrayelements CLOSEB',
  878. 'arrayelements ::= arrayelement',
  879. 'arrayelements ::= arrayelements COMMA arrayelement', 'arrayelements ::=',
  880. 'arrayelement ::= value APTR expr', 'arrayelement ::= ID APTR expr',
  881. 'arrayelement ::= expr', 'doublequoted_with_quotes ::= QUOTE QUOTE',
  882. 'doublequoted_with_quotes ::= QUOTE doublequoted QUOTE',
  883. 'doublequoted ::= doublequoted doublequotedcontent',
  884. 'doublequoted ::= doublequotedcontent',
  885. 'doublequotedcontent ::= BACKTICK variable BACKTICK',
  886. 'doublequotedcontent ::= BACKTICK expr BACKTICK',
  887. 'doublequotedcontent ::= DOLLARID', 'doublequotedcontent ::= LDEL variable RDEL',
  888. 'doublequotedcontent ::= LDEL expr RDEL', 'doublequotedcontent ::= smartytag',
  889. 'doublequotedcontent ::= TEXT',);
  890. public function tokenName($tokenType)
  891. {
  892. if ($tokenType === 0) {
  893. return 'End of Input';
  894. }
  895. if ($tokenType > 0 && $tokenType < count($this->yyTokenName)) {
  896. return $this->yyTokenName[ $tokenType ];
  897. } else {
  898. return "Unknown";
  899. }
  900. }
  901. public static function yy_destructor($yymajor, $yypminor)
  902. {
  903. switch ($yymajor) {
  904. default:
  905. break; /* If no destructor action specified: do nothing */
  906. }
  907. }
  908. public function yy_pop_parser_stack()
  909. {
  910. if (empty($this->yystack)) {
  911. return;
  912. }
  913. $yytos = array_pop($this->yystack);
  914. if ($this->yyTraceFILE && $this->yyidx >= 0) {
  915. fwrite($this->yyTraceFILE, $this->yyTracePrompt . 'Popping ' . $this->yyTokenName[ $yytos->major ] . "\n");
  916. }
  917. $yymajor = $yytos->major;
  918. self::yy_destructor($yymajor, $yytos->minor);
  919. $this->yyidx --;
  920. return $yymajor;
  921. }
  922. public function __destruct()
  923. {
  924. while ($this->yystack !== Array()) {
  925. $this->yy_pop_parser_stack();
  926. }
  927. if (is_resource($this->yyTraceFILE)) {
  928. fclose($this->yyTraceFILE);
  929. }
  930. }
  931. public function yy_get_expected_tokens($token)
  932. {
  933. static $res3 = array();
  934. static $res4 = array();
  935. $state = $this->yystack[ $this->yyidx ]->stateno;
  936. $expected = self::$yyExpectedTokens[ $state ];
  937. if (isset($res3[ $state ][ $token ])) {
  938. if ($res3[ $state ][ $token ]) {
  939. return $expected;
  940. }
  941. } else {
  942. if ($res3[ $state ][ $token ] = in_array($token, self::$yyExpectedTokens[ $state ], true)) {
  943. return $expected;
  944. }
  945. }
  946. $stack = $this->yystack;
  947. $yyidx = $this->yyidx;
  948. do {
  949. $yyact = $this->yy_find_shift_action($token);
  950. if ($yyact >= self::YYNSTATE && $yyact < self::YYNSTATE + self::YYNRULE) {
  951. // reduce action
  952. $done = 0;
  953. do {
  954. if ($done ++ == 100) {
  955. $this->yyidx = $yyidx;
  956. $this->yystack = $stack;
  957. // too much recursion prevents proper detection
  958. // so give up
  959. return array_unique($expected);
  960. }
  961. $yyruleno = $yyact - self::YYNSTATE;
  962. $this->yyidx -= self::$yyRuleInfo[ $yyruleno ][ 1 ];
  963. $nextstate = $this->yy_find_reduce_action($this->yystack[ $this->yyidx ]->stateno,
  964. self::$yyRuleInfo[ $yyruleno ][ 0 ]);
  965. if (isset(self::$yyExpectedTokens[ $nextstate ])) {
  966. $expected = array_merge($expected, self::$yyExpectedTokens[ $nextstate ]);
  967. if (isset($res4[ $nextstate ][ $token ])) {
  968. if ($res4[ $nextstate ][ $token ]) {
  969. $this->yyidx = $yyidx;
  970. $this->yystack = $stack;
  971. return array_unique($expected);
  972. }
  973. } else {
  974. if ($res4[ $nextstate ][ $token ] =
  975. in_array($token, self::$yyExpectedTokens[ $nextstate ], true)
  976. ) {
  977. $this->yyidx = $yyidx;
  978. $this->yystack = $stack;
  979. return array_unique($expected);
  980. }
  981. }
  982. }
  983. if ($nextstate < self::YYNSTATE) {
  984. // we need to shift a non-terminal
  985. $this->yyidx ++;
  986. $x = new TP_yyStackEntry;
  987. $x->stateno = $nextstate;
  988. $x->major = self::$yyRuleInfo[ $yyruleno ][ 0 ];
  989. $this->yystack[ $this->yyidx ] = $x;
  990. continue 2;
  991. } elseif ($nextstate == self::YYNSTATE + self::YYNRULE + 1) {
  992. $this->yyidx = $yyidx;
  993. $this->yystack = $stack;
  994. // the last token was just ignored, we can't accept
  995. // by ignoring input, this is in essence ignoring a
  996. // syntax error!
  997. return array_unique($expected);
  998. } elseif ($nextstate === self::YY_NO_ACTION) {
  999. $this->yyidx = $yyidx;
  1000. $this->yystack = $stack;
  1001. // input accepted, but not shifted (I guess)
  1002. return $expected;
  1003. } else {
  1004. $yyact = $nextstate;
  1005. }
  1006. } while (true);
  1007. }
  1008. break;
  1009. } while (true);
  1010. $this->yyidx = $yyidx;
  1011. $this->yystack = $stack;
  1012. return array_unique($expected);
  1013. }
  1014. public function yy_is_expected_token($token)
  1015. {
  1016. static $res = array();
  1017. static $res2 = array();
  1018. if ($token === 0) {
  1019. return true; // 0 is not part of this
  1020. }
  1021. $state = $this->yystack[ $this->yyidx ]->stateno;
  1022. if (isset($res[ $state ][ $token ])) {
  1023. if ($res[ $state ][ $token ]) {
  1024. return true;
  1025. }
  1026. } else {
  1027. if ($res[ $state ][ $token ] = in_array($token, self::$yyExpectedTokens[ $state ], true)) {
  1028. return true;
  1029. }
  1030. }
  1031. $stack = $this->yystack;
  1032. $yyidx = $this->yyidx;
  1033. do {
  1034. $yyact = $this->yy_find_shift_action($token);
  1035. if ($yyact >= self::YYNSTATE && $yyact < self::YYNSTATE + self::YYNRULE) {
  1036. // reduce action
  1037. $done = 0;
  1038. do {
  1039. if ($done ++ == 100) {
  1040. $this->yyidx = $yyidx;
  1041. $this->yystack = $stack;
  1042. // too much recursion prevents proper detection
  1043. // so give up
  1044. return true;
  1045. }
  1046. $yyruleno = $yyact - self::YYNSTATE;
  1047. $this->yyidx -= self::$yyRuleInfo[ $yyruleno ][ 1 ];
  1048. $nextstate = $this->yy_find_reduce_action($this->yystack[ $this->yyidx ]->stateno,
  1049. self::$yyRuleInfo[ $yyruleno ][ 0 ]);
  1050. if (isset($res2[ $nextstate ][ $token ])) {
  1051. if ($res2[ $nextstate ][ $token ]) {
  1052. $this->yyidx = $yyidx;
  1053. $this->yystack = $stack;
  1054. return true;
  1055. }
  1056. } else {
  1057. if ($res2[ $nextstate ][ $token ] = (isset(self::$yyExpectedTokens[ $nextstate ]) &&
  1058. in_array($token, self::$yyExpectedTokens[ $nextstate ], true))
  1059. ) {
  1060. $this->yyidx = $yyidx;
  1061. $this->yystack = $stack;
  1062. return true;
  1063. }
  1064. }
  1065. if ($nextstate < self::YYNSTATE) {
  1066. // we need to shift a non-terminal
  1067. $this->yyidx ++;
  1068. $x = new TP_yyStackEntry;
  1069. $x->stateno = $nextstate;
  1070. $x->major = self::$yyRuleInfo[ $yyruleno ][ 0 ];
  1071. $this->yystack[ $this->yyidx ] = $x;
  1072. continue 2;
  1073. } elseif ($nextstate == self::YYNSTATE + self::YYNRULE + 1) {
  1074. $this->yyidx = $yyidx;
  1075. $this->yystack = $stack;
  1076. if (!$token) {
  1077. // end of input: this is valid
  1078. return true;
  1079. }
  1080. // the last token was just ignored, we can't accept
  1081. // by ignoring input, this is in essence ignoring a
  1082. // syntax error!
  1083. return false;
  1084. } elseif ($nextstate === self::YY_NO_ACTION) {
  1085. $this->yyidx = $yyidx;
  1086. $this->yystack = $stack;
  1087. // input accepted, but not shifted (I guess)
  1088. return true;
  1089. } else {
  1090. $yyact = $nextstate;
  1091. }
  1092. } while (true);
  1093. }
  1094. break;
  1095. } while (true);
  1096. $this->yyidx = $yyidx;
  1097. $this->yystack = $stack;
  1098. return true;
  1099. }
  1100. public function yy_find_shift_action($iLookAhead)
  1101. {
  1102. $stateno = $this->yystack[ $this->yyidx ]->stateno;
  1103. /* if ($this->yyidx < 0) return self::YY_NO_ACTION; */
  1104. if (!isset(self::$yy_shift_ofst[ $stateno ])) {
  1105. // no shift actions
  1106. return self::$yy_default[ $stateno ];
  1107. }
  1108. $i = self::$yy_shift_ofst[ $stateno ];
  1109. if ($i === self::YY_SHIFT_USE_DFLT) {
  1110. return self::$yy_default[ $stateno ];
  1111. }
  1112. if ($iLookAhead == self::YYNOCODE) {
  1113. return self::YY_NO_ACTION;
  1114. }
  1115. $i += $iLookAhead;
  1116. if ($i < 0 || $i >= self::YY_SZ_ACTTAB || self::$yy_lookahead[ $i ] != $iLookAhead) {
  1117. if (count(self::$yyFallback) && $iLookAhead < count(self::$yyFallback) &&
  1118. ($iFallback = self::$yyFallback[ $iLookAhead ]) != 0
  1119. ) {
  1120. if ($this->yyTraceFILE) {
  1121. fwrite($this->yyTraceFILE,
  1122. $this->yyTracePrompt . "FALLBACK " . $this->yyTokenName[ $iLookAhead ] . " => " .
  1123. $this->yyTokenName[ $iFallback ] . "\n");
  1124. }
  1125. return $this->yy_find_shift_action($iFallback);
  1126. }
  1127. return self::$yy_default[ $stateno ];
  1128. } else {
  1129. return self::$yy_action[ $i ];
  1130. }
  1131. }
  1132. public function yy_find_reduce_action($stateno, $iLookAhead)
  1133. {
  1134. /* $stateno = $this->yystack[$this->yyidx]->stateno; */
  1135. if (!isset(self::$yy_reduce_ofst[ $stateno ])) {
  1136. return self::$yy_default[ $stateno ];
  1137. }
  1138. $i = self::$yy_reduce_ofst[ $stateno ];
  1139. if ($i == self::YY_REDUCE_USE_DFLT) {
  1140. return self::$yy_default[ $stateno ];
  1141. }
  1142. if ($iLookAhead == self::YYNOCODE) {
  1143. return self::YY_NO_ACTION;
  1144. }
  1145. $i += $iLookAhead;
  1146. if ($i < 0 || $i >= self::YY_SZ_ACTTAB || self::$yy_lookahead[ $i ] != $iLookAhead) {
  1147. return self::$yy_default[ $stateno ];
  1148. } else {
  1149. return self::$yy_action[ $i ];
  1150. }
  1151. }
  1152. public function yy_shift($yyNewState, $yyMajor, $yypMinor)
  1153. {
  1154. $this->yyidx ++;
  1155. if ($this->yyidx >= self::YYSTACKDEPTH) {
  1156. $this->yyidx --;
  1157. if ($this->yyTraceFILE) {
  1158. fprintf($this->yyTraceFILE, "%sStack Overflow!\n", $this->yyTracePrompt);
  1159. }
  1160. while ($this->yyidx >= 0) {
  1161. $this->yy_pop_parser_stack();
  1162. }
  1163. #line 214 "../smarty/lexer/smarty_internal_templateparser.y"
  1164. $this->internalError = true;
  1165. $this->compiler->trigger_template_error("Stack overflow in template parser");
  1166. return;
  1167. }
  1168. $yytos = new TP_yyStackEntry;
  1169. $yytos->stateno = $yyNewState;
  1170. $yytos->major = $yyMajor;
  1171. $yytos->minor = $yypMinor;
  1172. $this->yystack[] = $yytos;
  1173. if ($this->yyTraceFILE && $this->yyidx > 0) {
  1174. fprintf($this->yyTraceFILE, "%sShift %d\n", $this->yyTracePrompt, $yyNewState);
  1175. fprintf($this->yyTraceFILE, "%sStack:", $this->yyTracePrompt);
  1176. for ($i = 1; $i <= $this->yyidx; $i ++) {
  1177. fprintf($this->yyTraceFILE, " %s", $this->yyTokenName[ $this->yystack[ $i ]->major ]);
  1178. }
  1179. fwrite($this->yyTraceFILE, "\n");
  1180. }
  1181. }
  1182. public static $yyRuleInfo = array(array(0 => 61, 1 => 1), array(0 => 62, 1 => 1), array(0 => 62, 1 => 2),
  1183. array(0 => 62, 1 => 0), array(0 => 63, 1 => 1), array(0 => 63, 1 => 1),
  1184. array(0 => 63, 1 => 1), array(0 => 63, 1 => 1), array(0 => 63, 1 => 1),
  1185. array(0 => 66, 1 => 1), array(0 => 66, 1 => 2), array(0 => 63, 1 => 1),
  1186. array(0 => 63, 1 => 1), array(0 => 65, 1 => 2), array(0 => 65, 1 => 3),
  1187. array(0 => 67, 1 => 2), array(0 => 67, 1 => 0), array(0 => 68, 1 => 1),
  1188. array(0 => 68, 1 => 1), array(0 => 64, 1 => 2), array(0 => 64, 1 => 1),
  1189. array(0 => 69, 1 => 2), array(0 => 69, 1 => 3), array(0 => 69, 1 => 2),
  1190. array(0 => 69, 1 => 3), array(0 => 69, 1 => 2), array(0 => 69, 1 => 3),
  1191. array(0 => 69, 1 => 4), array(0 => 69, 1 => 4), array(0 => 69, 1 => 5),
  1192. array(0 => 69, 1 => 5), array(0 => 64, 1 => 1), array(0 => 69, 1 => 3),
  1193. array(0 => 69, 1 => 2), array(0 => 69, 1 => 4), array(0 => 69, 1 => 5),
  1194. array(0 => 69, 1 => 6), array(0 => 69, 1 => 2), array(0 => 69, 1 => 3),
  1195. array(0 => 69, 1 => 2), array(0 => 69, 1 => 3), array(0 => 69, 1 => 8),
  1196. array(0 => 78, 1 => 2), array(0 => 78, 1 => 1), array(0 => 69, 1 => 5),
  1197. array(0 => 69, 1 => 7), array(0 => 69, 1 => 2), array(0 => 69, 1 => 6),
  1198. array(0 => 69, 1 => 8), array(0 => 69, 1 => 6), array(0 => 69, 1 => 8),
  1199. array(0 => 69, 1 => 3), array(0 => 69, 1 => 4), array(0 => 69, 1 => 2),
  1200. array(0 => 64, 1 => 1), array(0 => 69, 1 => 2), array(0 => 69, 1 => 3),
  1201. array(0 => 69, 1 => 4), array(0 => 69, 1 => 5), array(0 => 71, 1 => 2),
  1202. array(0 => 71, 1 => 1), array(0 => 71, 1 => 0), array(0 => 81, 1 => 4),
  1203. array(0 => 81, 1 => 2), array(0 => 81, 1 => 2), array(0 => 81, 1 => 2),
  1204. array(0 => 81, 1 => 2), array(0 => 81, 1 => 2), array(0 => 81, 1 => 4),
  1205. array(0 => 77, 1 => 1), array(0 => 77, 1 => 3), array(0 => 76, 1 => 3),
  1206. array(0 => 76, 1 => 3), array(0 => 76, 1 => 3), array(0 => 76, 1 => 3),
  1207. array(0 => 73, 1 => 1), array(0 => 73, 1 => 1), array(0 => 73, 1 => 3),
  1208. array(0 => 73, 1 => 3), array(0 => 73, 1 => 3), array(0 => 73, 1 => 1),
  1209. array(0 => 73, 1 => 2), array(0 => 73, 1 => 3), array(0 => 73, 1 => 2),
  1210. array(0 => 73, 1 => 3), array(0 => 73, 1 => 3), array(0 => 73, 1 => 3),
  1211. array(0 => 73, 1 => 3), array(0 => 82, 1 => 7), array(0 => 82, 1 => 7),
  1212. array(0 => 72, 1 => 1), array(0 => 72, 1 => 2), array(0 => 72, 1 => 2),
  1213. array(0 => 72, 1 => 2), array(0 => 72, 1 => 2), array(0 => 72, 1 => 1),
  1214. array(0 => 72, 1 => 1), array(0 => 72, 1 => 3), array(0 => 72, 1 => 2),
  1215. array(0 => 72, 1 => 2), array(0 => 72, 1 => 1), array(0 => 72, 1 => 1),
  1216. array(0 => 72, 1 => 3), array(0 => 72, 1 => 1), array(0 => 72, 1 => 1),
  1217. array(0 => 72, 1 => 3), array(0 => 72, 1 => 1), array(0 => 72, 1 => 2),
  1218. array(0 => 72, 1 => 1), array(0 => 72, 1 => 3), array(0 => 86, 1 => 1),
  1219. array(0 => 86, 1 => 1), array(0 => 70, 1 => 1), array(0 => 70, 1 => 1),
  1220. array(0 => 70, 1 => 3), array(0 => 70, 1 => 1), array(0 => 70, 1 => 3),
  1221. array(0 => 70, 1 => 4), array(0 => 70, 1 => 3), array(0 => 70, 1 => 4),
  1222. array(0 => 74, 1 => 2), array(0 => 74, 1 => 2), array(0 => 91, 1 => 2),
  1223. array(0 => 91, 1 => 0), array(0 => 92, 1 => 2), array(0 => 92, 1 => 2),
  1224. array(0 => 92, 1 => 4), array(0 => 92, 1 => 2), array(0 => 92, 1 => 2),
  1225. array(0 => 92, 1 => 4), array(0 => 92, 1 => 3), array(0 => 92, 1 => 5),
  1226. array(0 => 92, 1 => 3), array(0 => 92, 1 => 3), array(0 => 92, 1 => 3),
  1227. array(0 => 92, 1 => 3), array(0 => 92, 1 => 3), array(0 => 92, 1 => 3),
  1228. array(0 => 92, 1 => 2), array(0 => 79, 1 => 1), array(0 => 79, 1 => 1),
  1229. array(0 => 79, 1 => 2), array(0 => 93, 1 => 1), array(0 => 93, 1 => 1),
  1230. array(0 => 93, 1 => 3), array(0 => 90, 1 => 2), array(0 => 94, 1 => 1),
  1231. array(0 => 94, 1 => 2), array(0 => 95, 1 => 3), array(0 => 95, 1 => 3),
  1232. array(0 => 95, 1 => 5), array(0 => 95, 1 => 6), array(0 => 95, 1 => 2),
  1233. array(0 => 87, 1 => 4), array(0 => 96, 1 => 4), array(0 => 96, 1 => 4),
  1234. array(0 => 97, 1 => 3), array(0 => 97, 1 => 1), array(0 => 97, 1 => 0),
  1235. array(0 => 75, 1 => 3), array(0 => 75, 1 => 2), array(0 => 98, 1 => 3),
  1236. array(0 => 98, 1 => 2), array(0 => 80, 1 => 2), array(0 => 80, 1 => 0),
  1237. array(0 => 99, 1 => 2), array(0 => 99, 1 => 2), array(0 => 89, 1 => 1),
  1238. array(0 => 89, 1 => 2), array(0 => 89, 1 => 1), array(0 => 89, 1 => 2),
  1239. array(0 => 89, 1 => 3), array(0 => 84, 1 => 1), array(0 => 84, 1 => 1),
  1240. array(0 => 85, 1 => 1), array(0 => 83, 1 => 3), array(0 => 100, 1 => 1),
  1241. array(0 => 100, 1 => 3), array(0 => 100, 1 => 0), array(0 => 101, 1 => 3),
  1242. array(0 => 101, 1 => 3), array(0 => 101, 1 => 1), array(0 => 88, 1 => 2),
  1243. array(0 => 88, 1 => 3), array(0 => 102, 1 => 2), array(0 => 102, 1 => 1),
  1244. array(0 => 103, 1 => 3), array(0 => 103, 1 => 3), array(0 => 103, 1 => 1),
  1245. array(0 => 103, 1 => 3), array(0 => 103, 1 => 3), array(0 => 103, 1 => 1),
  1246. array(0 => 103, 1 => 1),);
  1247. public static $yyReduceMap = array(0 => 0, 1 => 1, 2 => 2, 4 => 4, 5 => 5, 6 => 6, 7 => 7, 8 => 8, 9 => 9,
  1248. 17 => 9, 18 => 9, 43 => 9, 66 => 9, 67 => 9, 75 => 9, 76 => 9, 80 => 9, 90 => 9,
  1249. 95 => 9, 96 => 9, 101 => 9, 103 => 9, 104 => 9, 108 => 9, 110 => 9, 115 => 9,
  1250. 176 => 9, 181 => 9, 10 => 10, 11 => 11, 12 => 12, 13 => 13, 16 => 13, 14 => 14,
  1251. 74 => 14, 15 => 15, 91 => 15, 93 => 15, 94 => 15, 122 => 15, 19 => 19, 20 => 20,
  1252. 21 => 21, 23 => 21, 25 => 21, 22 => 22, 24 => 22, 26 => 22, 27 => 27, 28 => 27,
  1253. 29 => 29, 30 => 30, 31 => 31, 32 => 32, 33 => 33, 34 => 34, 35 => 35, 36 => 36,
  1254. 37 => 37, 38 => 38, 40 => 38, 39 => 39, 41 => 41, 42 => 42, 44 => 44, 45 => 45,
  1255. 46 => 46, 47 => 47, 49 => 47, 48 => 48, 50 => 48, 51 => 51, 52 => 52, 53 => 53,
  1256. 54 => 54, 55 => 55, 56 => 56, 57 => 57, 58 => 58, 59 => 59, 60 => 60, 69 => 60,
  1257. 157 => 60, 161 => 60, 165 => 60, 166 => 60, 61 => 61, 158 => 61, 164 => 61,
  1258. 62 => 62, 63 => 63, 64 => 63, 65 => 65, 142 => 65, 68 => 68, 70 => 70, 71 => 71,
  1259. 72 => 71, 73 => 73, 77 => 77, 78 => 78, 79 => 78, 81 => 81, 107 => 81, 82 => 82,
  1260. 83 => 83, 84 => 84, 85 => 85, 86 => 86, 87 => 86, 88 => 88, 89 => 89, 92 => 92,
  1261. 97 => 97, 98 => 98, 99 => 99, 100 => 100, 102 => 102, 105 => 105, 106 => 106,
  1262. 109 => 109, 111 => 111, 112 => 112, 113 => 113, 114 => 114, 116 => 116,
  1263. 117 => 117, 118 => 118, 119 => 119, 120 => 120, 121 => 121, 123 => 123,
  1264. 178 => 123, 124 => 124, 125 => 125, 126 => 126, 127 => 127, 128 => 128,
  1265. 129 => 129, 137 => 129, 130 => 130, 131 => 131, 132 => 132, 133 => 132,
  1266. 135 => 132, 136 => 132, 134 => 134, 138 => 138, 139 => 139, 140 => 140,
  1267. 182 => 140, 141 => 141, 143 => 143, 144 => 144, 145 => 145, 146 => 146,
  1268. 147 => 147, 148 => 148, 149 => 149, 150 => 150, 151 => 151, 152 => 152,
  1269. 153 => 153, 154 => 154, 155 => 155, 156 => 156, 159 => 159, 160 => 160,
  1270. 162 => 162, 163 => 163, 167 => 167, 168 => 168, 169 => 169, 170 => 170,
  1271. 171 => 171, 172 => 172, 173 => 173, 174 => 174, 175 => 175, 177 => 177,
  1272. 179 => 179, 180 => 180, 183 => 183, 184 => 184, 185 => 185, 186 => 186,
  1273. 187 => 186, 189 => 186, 188 => 188, 190 => 190, 191 => 191, 192 => 192,);
  1274. #line 225 "../smarty/lexer/smarty_internal_templateparser.y"
  1275. function yy_r0()
  1276. {
  1277. $this->root_buffer->prepend_array($this, $this->template_prefix);
  1278. $this->root_buffer->append_array($this, $this->template_postfix);
  1279. $this->_retvalue = $this->root_buffer->to_smarty_php($this);
  1280. }
  1281. #line 235 "../smarty/lexer/smarty_internal_templateparser.y"
  1282. function yy_r1()
  1283. {
  1284. if ($this->yystack[ $this->yyidx + 0 ]->minor != null) {
  1285. $this->current_buffer->append_subtree($this, $this->yystack[ $this->yyidx + 0 ]->minor);
  1286. }
  1287. }
  1288. #line 242 "../smarty/lexer/smarty_internal_templateparser.y"
  1289. function yy_r2()
  1290. {
  1291. if ($this->yystack[ $this->yyidx + 0 ]->minor != null) {
  1292. // because of possible code injection
  1293. $this->current_buffer->append_subtree($this, $this->yystack[ $this->yyidx + 0 ]->minor);
  1294. }
  1295. }
  1296. #line 256 "../smarty/lexer/smarty_internal_templateparser.y"
  1297. function yy_r4()
  1298. {
  1299. if ($this->compiler->has_code) {
  1300. $this->_retvalue = $this->mergePrefixCode($this->yystack[ $this->yyidx + 0 ]->minor);
  1301. } else {
  1302. $this->_retvalue = null;
  1303. }
  1304. $this->compiler->has_variable_string = false;
  1305. $this->block_nesting_level = count($this->compiler->_tag_stack);
  1306. }
  1307. #line 267 "../smarty/lexer/smarty_internal_templateparser.y"
  1308. function yy_r5()
  1309. {
  1310. $this->_retvalue = new Smarty_Internal_ParseTree_Text($this->yystack[ $this->yyidx + 0 ]->minor);
  1311. }
  1312. #line 271 "../smarty/lexer/smarty_internal_templateparser.y"
  1313. function yy_r6()
  1314. {
  1315. $code = $this->compiler->compileTag('private_php',
  1316. array(array('code' => $this->yystack[ $this->yyidx + 0 ]->minor),
  1317. array('type' => $this->lex->phpType)), array());
  1318. if ($this->compiler->has_code && !empty($code)) {
  1319. $tmp = '';
  1320. foreach ($this->compiler->prefix_code as $code) {
  1321. $tmp .= $code;
  1322. }
  1323. $this->compiler->prefix_code = array();
  1324. $this->_retvalue =
  1325. new Smarty_Internal_ParseTree_Tag($this, $this->compiler->processNocacheCode($tmp . $code, true));
  1326. } else {
  1327. $this->_retvalue = null;
  1328. }
  1329. }
  1330. #line 282 "../smarty/lexer/smarty_internal_templateparser.y"
  1331. function yy_r7()
  1332. {
  1333. $this->compiler->tag_nocache = true;
  1334. $save = $this->template->compiled->has_nocache_code;
  1335. $this->_retvalue = new Smarty_Internal_ParseTree_Tag($this,
  1336. $this->compiler->processNocacheCode("<?php echo '{$this->yystack[$this->yyidx + 0]->minor}';?>\n",
  1337. $this->compiler,
  1338. true));
  1339. $this->template->compiled->has_nocache_code = $save;
  1340. }
  1341. #line 289 "../smarty/lexer/smarty_internal_templateparser.y"
  1342. function yy_r8()
  1343. {
  1344. $this->_retvalue = $this->compiler->processText($this->yystack[ $this->yyidx + 0 ]->minor);
  1345. }
  1346. #line 293 "../smarty/lexer/smarty_internal_templateparser.y"
  1347. function yy_r9()
  1348. {
  1349. $this->_retvalue = $this->yystack[ $this->yyidx + 0 ]->minor;
  1350. }
  1351. #line 297 "../smarty/lexer/smarty_internal_templateparser.y"
  1352. function yy_r10()
  1353. {
  1354. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor . $this->yystack[ $this->yyidx + 0 ]->minor;
  1355. }
  1356. #line 302 "../smarty/lexer/smarty_internal_templateparser.y"
  1357. function yy_r11()
  1358. {
  1359. $this->strip = true;
  1360. }
  1361. #line 306 "../smarty/lexer/smarty_internal_templateparser.y"
  1362. function yy_r12()
  1363. {
  1364. $this->strip = false;
  1365. }
  1366. #line 311 "../smarty/lexer/smarty_internal_templateparser.y"
  1367. function yy_r13()
  1368. {
  1369. $this->_retvalue = '';
  1370. }
  1371. #line 315 "../smarty/lexer/smarty_internal_templateparser.y"
  1372. function yy_r14()
  1373. {
  1374. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor;
  1375. }
  1376. #line 319 "../smarty/lexer/smarty_internal_templateparser.y"
  1377. function yy_r15()
  1378. {
  1379. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor . $this->yystack[ $this->yyidx + 0 ]->minor;
  1380. }
  1381. #line 335 "../smarty/lexer/smarty_internal_templateparser.y"
  1382. function yy_r19()
  1383. {
  1384. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor;
  1385. }
  1386. #line 341 "../smarty/lexer/smarty_internal_templateparser.y"
  1387. function yy_r20()
  1388. {
  1389. $var =
  1390. trim(substr($this->yystack[ $this->yyidx + 0 ]->minor, $this->lex->ldel_length, - $this->lex->rdel_length),
  1391. ' $');
  1392. if (preg_match('/^(.*)(\s+nocache)$/', $var, $match)) {
  1393. $this->_retvalue = $this->compiler->compileTag('private_print_expression', array('nocache'),
  1394. array('value' => $this->compiler->compileVariable('\'' .
  1395. $match[ 1 ] .
  1396. '\'')));
  1397. } else {
  1398. $this->_retvalue = $this->compiler->compileTag('private_print_expression', array(),
  1399. array('value' => $this->compiler->compileVariable('\'' .
  1400. $var .
  1401. '\'')));
  1402. }
  1403. }
  1404. #line 351 "../smarty/lexer/smarty_internal_templateparser.y"
  1405. function yy_r21()
  1406. {
  1407. $this->_retvalue = $this->compiler->compileTag('private_print_expression', array(),
  1408. array('value' => $this->yystack[ $this->yyidx + 0 ]->minor));
  1409. }
  1410. #line 355 "../smarty/lexer/smarty_internal_templateparser.y"
  1411. function yy_r22()
  1412. {
  1413. $this->_retvalue =
  1414. $this->compiler->compileTag('private_print_expression', $this->yystack[ $this->yyidx + 0 ]->minor,
  1415. array('value' => $this->yystack[ $this->yyidx + - 1 ]->minor));
  1416. }
  1417. #line 378 "../smarty/lexer/smarty_internal_templateparser.y"
  1418. function yy_r27()
  1419. {
  1420. $this->_retvalue = $this->compiler->compileTag('assign', array(array('value' => $this->yystack[ $this->yyidx +
  1421. 0 ]->minor), array('var' => '\'' . substr($this->yystack[ $this->yyidx + - 2 ]->minor, 1) . '\'')));
  1422. }
  1423. #line 386 "../smarty/lexer/smarty_internal_templateparser.y"
  1424. function yy_r29()
  1425. {
  1426. $this->_retvalue = $this->compiler->compileTag('assign',
  1427. array_merge(array(array('value' => $this->yystack[ $this->yyidx +
  1428. - 1 ]->minor), array('var' => '\'' .
  1429. substr($this->yystack[ $this->yyidx + - 3 ]->minor, 1) .
  1430. '\'')), $this->yystack[ $this->yyidx + 0 ]->minor));
  1431. }
  1432. #line 390 "../smarty/lexer/smarty_internal_templateparser.y"
  1433. function yy_r30()
  1434. {
  1435. $this->_retvalue = $this->compiler->compileTag('assign',
  1436. array_merge(array(array('value' => $this->yystack[ $this->yyidx +
  1437. - 1 ]->minor), array('var' => $this->yystack[ $this->yyidx +
  1438. - 3 ]->minor[ 'var' ])),
  1439. $this->yystack[ $this->yyidx + 0 ]->minor),
  1440. array('smarty_internal_index' => $this->yystack[ $this->yyidx +
  1441. - 3 ]->minor[ 'smarty_internal_index' ]));
  1442. }
  1443. #line 395 "../smarty/lexer/smarty_internal_templateparser.y"
  1444. function yy_r31()
  1445. {
  1446. $tag =
  1447. trim(substr($this->yystack[ $this->yyidx + 0 ]->minor, $this->lex->ldel_length, - $this->lex->rdel_length));
  1448. if ($tag == 'strip') {
  1449. $this->strip = true;
  1450. $this->_retvalue = null;;
  1451. } else {
  1452. if (defined($tag)) {
  1453. if ($this->security) {
  1454. $this->security->isTrustedConstant($tag, $this->compiler);
  1455. }
  1456. $this->_retvalue =
  1457. $this->compiler->compileTag('private_print_expression', array(), array('value' => $tag));
  1458. } else {
  1459. if (preg_match('/^(.*)(\s+nocache)$/', $tag, $match)) {
  1460. $this->_retvalue = $this->compiler->compileTag($match[ 1 ], array("'nocache'"));
  1461. } else {
  1462. $this->_retvalue = $this->compiler->compileTag($tag, array());
  1463. }
  1464. }
  1465. }
  1466. }
  1467. #line 417 "../smarty/lexer/smarty_internal_templateparser.y"
  1468. function yy_r32()
  1469. {
  1470. if (defined($this->yystack[ $this->yyidx + - 1 ]->minor)) {
  1471. if ($this->security) {
  1472. $this->security->isTrustedConstant($this->yystack[ $this->yyidx + - 1 ]->minor, $this->compiler);
  1473. }
  1474. $this->_retvalue =
  1475. $this->compiler->compileTag('private_print_expression', $this->yystack[ $this->yyidx + 0 ]->minor,
  1476. array('value' => $this->yystack[ $this->yyidx + - 1 ]->minor));
  1477. } else {
  1478. $this->_retvalue = $this->compiler->compileTag($this->yystack[ $this->yyidx + - 1 ]->minor,
  1479. $this->yystack[ $this->yyidx + 0 ]->minor);
  1480. }
  1481. }
  1482. #line 427 "../smarty/lexer/smarty_internal_templateparser.y"
  1483. function yy_r33()
  1484. {
  1485. if (defined($this->yystack[ $this->yyidx + 0 ]->minor)) {
  1486. if ($this->security) {
  1487. $this->security->isTrustedConstant($this->yystack[ $this->yyidx + 0 ]->minor, $this->compiler);
  1488. }
  1489. $this->_retvalue = $this->compiler->compileTag('private_print_expression', array(),
  1490. array('value' => $this->yystack[ $this->yyidx + 0 ]->minor));
  1491. } else {
  1492. $this->_retvalue = $this->compiler->compileTag($this->yystack[ $this->yyidx + 0 ]->minor, array());
  1493. }
  1494. }
  1495. #line 440 "../smarty/lexer/smarty_internal_templateparser.y"
  1496. function yy_r34()
  1497. {
  1498. if (defined($this->yystack[ $this->yyidx + - 2 ]->minor)) {
  1499. if ($this->security) {
  1500. $this->security->isTrustedConstant($this->yystack[ $this->yyidx + - 2 ]->minor, $this->compiler);
  1501. }
  1502. $this->_retvalue =
  1503. $this->compiler->compileTag('private_print_expression', $this->yystack[ $this->yyidx + 0 ]->minor,
  1504. array('value' => $this->yystack[ $this->yyidx + - 2 ]->minor,
  1505. 'modifierlist' => $this->yystack[ $this->yyidx + - 1 ]->minor));
  1506. } else {
  1507. $this->_retvalue = '<?php ob_start();?>' .
  1508. $this->compiler->compileTag($this->yystack[ $this->yyidx + - 2 ]->minor,
  1509. $this->yystack[ $this->yyidx + 0 ]->minor) . '<?php echo ';
  1510. $this->_retvalue .= $this->compiler->compileTag('private_modifier', array(),
  1511. array('modifierlist' => $this->yystack[ $this->yyidx +
  1512. - 1 ]->minor, 'value' => 'ob_get_clean()')) . ';?>';
  1513. }
  1514. }
  1515. #line 453 "../smarty/lexer/smarty_internal_templateparser.y"
  1516. function yy_r35()
  1517. {
  1518. $this->_retvalue = $this->compiler->compileTag($this->yystack[ $this->yyidx + - 3 ]->minor,
  1519. $this->yystack[ $this->yyidx + 0 ]->minor,
  1520. array('object_method' => $this->yystack[ $this->yyidx +
  1521. - 1 ]->minor));
  1522. }
  1523. #line 458 "../smarty/lexer/smarty_internal_templateparser.y"
  1524. function yy_r36()
  1525. {
  1526. $this->_retvalue = '<?php ob_start();?>' .
  1527. $this->compiler->compileTag($this->yystack[ $this->yyidx + - 4 ]->minor,
  1528. $this->yystack[ $this->yyidx + 0 ]->minor,
  1529. array('object_method' => $this->yystack[ $this->yyidx + - 2 ]->minor)) .
  1530. '<?php echo ';
  1531. $this->_retvalue .= $this->compiler->compileTag('private_modifier', array(),
  1532. array('modifierlist' => $this->yystack[ $this->yyidx +
  1533. - 1 ]->minor, 'value' => 'ob_get_clean()')) . ';?>';
  1534. }
  1535. #line 464 "../smarty/lexer/smarty_internal_templateparser.y"
  1536. function yy_r37()
  1537. {
  1538. $tag = trim(substr($this->yystack[ $this->yyidx + - 1 ]->minor, $this->lex->ldel_length));
  1539. $this->_retvalue = $this->compiler->compileTag(($tag == 'else if') ? 'elseif' : $tag, array(),
  1540. array('if condition' => $this->yystack[ $this->yyidx +
  1541. 0 ]->minor));
  1542. }
  1543. #line 469 "../smarty/lexer/smarty_internal_templateparser.y"
  1544. function yy_r38()
  1545. {
  1546. $tag = trim(substr($this->yystack[ $this->yyidx + - 2 ]->minor, $this->lex->ldel_length));
  1547. $this->_retvalue = $this->compiler->compileTag(($tag == 'else if') ? 'elseif' : $tag,
  1548. $this->yystack[ $this->yyidx + 0 ]->minor,
  1549. array('if condition' => $this->yystack[ $this->yyidx +
  1550. - 1 ]->minor));
  1551. }
  1552. #line 474 "../smarty/lexer/smarty_internal_templateparser.y"
  1553. function yy_r39()
  1554. {
  1555. $tag = trim(substr($this->yystack[ $this->yyidx + - 1 ]->minor, $this->lex->ldel_length));
  1556. $this->_retvalue = $this->compiler->compileTag(($tag == 'else if') ? 'elseif' : $tag, array(),
  1557. array('if condition' => $this->yystack[ $this->yyidx +
  1558. 0 ]->minor));
  1559. }
  1560. #line 485 "../smarty/lexer/smarty_internal_templateparser.y"
  1561. function yy_r41()
  1562. {
  1563. $this->_retvalue = $this->compiler->compileTag('for', array_merge($this->yystack[ $this->yyidx + 0 ]->minor,
  1564. array(array('start' => $this->yystack[ $this->yyidx +
  1565. - 6 ]->minor),
  1566. array('ifexp' => $this->yystack[ $this->yyidx +
  1567. - 4 ]->minor),
  1568. array('var' => $this->yystack[ $this->yyidx +
  1569. - 2 ]->minor),
  1570. array('step' => $this->yystack[ $this->yyidx +
  1571. - 1 ]->minor))), 1);
  1572. }
  1573. #line 489 "../smarty/lexer/smarty_internal_templateparser.y"
  1574. function yy_r42()
  1575. {
  1576. $this->_retvalue = '=' . $this->yystack[ $this->yyidx + 0 ]->minor;
  1577. }
  1578. #line 497 "../smarty/lexer/smarty_internal_templateparser.y"
  1579. function yy_r44()
  1580. {
  1581. $this->_retvalue = $this->compiler->compileTag('for', array_merge($this->yystack[ $this->yyidx + 0 ]->minor,
  1582. array(array('start' => $this->yystack[ $this->yyidx +
  1583. - 3 ]->minor),
  1584. array('to' => $this->yystack[ $this->yyidx +
  1585. - 1 ]->minor))), 0);
  1586. }
  1587. #line 501 "../smarty/lexer/smarty_internal_templateparser.y"
  1588. function yy_r45()
  1589. {
  1590. $this->_retvalue = $this->compiler->compileTag('for', array_merge($this->yystack[ $this->yyidx + 0 ]->minor,
  1591. array(array('start' => $this->yystack[ $this->yyidx +
  1592. - 5 ]->minor),
  1593. array('to' => $this->yystack[ $this->yyidx +
  1594. - 3 ]->minor),
  1595. array('step' => $this->yystack[ $this->yyidx +
  1596. - 1 ]->minor))), 0);
  1597. }
  1598. #line 506 "../smarty/lexer/smarty_internal_templateparser.y"
  1599. function yy_r46()
  1600. {
  1601. $this->_retvalue = $this->compiler->compileTag('foreach', $this->yystack[ $this->yyidx + 0 ]->minor);
  1602. }
  1603. #line 511 "../smarty/lexer/smarty_internal_templateparser.y"
  1604. function yy_r47()
  1605. {
  1606. $this->_retvalue = $this->compiler->compileTag('foreach', array_merge($this->yystack[ $this->yyidx + 0 ]->minor,
  1607. array(array('from' => $this->yystack[ $this->yyidx +
  1608. - 3 ]->minor),
  1609. array('item' => $this->yystack[ $this->yyidx +
  1610. - 1 ]->minor))));
  1611. }
  1612. #line 515 "../smarty/lexer/smarty_internal_templateparser.y"
  1613. function yy_r48()
  1614. {
  1615. $this->_retvalue = $this->compiler->compileTag('foreach', array_merge($this->yystack[ $this->yyidx + 0 ]->minor,
  1616. array(array('from' => $this->yystack[ $this->yyidx +
  1617. - 5 ]->minor),
  1618. array('item' => $this->yystack[ $this->yyidx +
  1619. - 1 ]->minor),
  1620. array('key' => $this->yystack[ $this->yyidx +
  1621. - 3 ]->minor))));
  1622. }
  1623. #line 528 "../smarty/lexer/smarty_internal_templateparser.y"
  1624. function yy_r51()
  1625. {
  1626. $this->_retvalue = $this->compiler->compileTag('setfilter', array(),
  1627. array('modifier_list' => array(array_merge(array($this->yystack[ $this->yyidx +
  1628. - 1 ]->minor), $this->yystack[ $this->yyidx + 0 ]->minor))));
  1629. }
  1630. #line 532 "../smarty/lexer/smarty_internal_templateparser.y"
  1631. function yy_r52()
  1632. {
  1633. $this->_retvalue = $this->compiler->compileTag('setfilter', array(),
  1634. array('modifier_list' => array_merge(array(array_merge(array($this->yystack[ $this->yyidx +
  1635. - 2 ]->minor), $this->yystack[ $this->yyidx + - 1 ]->minor)),
  1636. $this->yystack[ $this->yyidx +
  1637. 0 ]->minor)));
  1638. }
  1639. #line 537 "../smarty/lexer/smarty_internal_templateparser.y"
  1640. function yy_r53()
  1641. {
  1642. $j = strrpos($this->yystack[ $this->yyidx + 0 ]->minor, '.');
  1643. if ($this->yystack[ $this->yyidx + 0 ]->minor[ $j + 1 ] == 'c') {
  1644. // {$smarty.block.child}
  1645. $this->_retvalue = SMARTY_INTERNAL_COMPILE_BLOCK::compileChildBlock($this->compiler);
  1646. } else {
  1647. // {$smarty.block.parent}
  1648. $this->_retvalue = SMARTY_INTERNAL_COMPILE_BLOCK::compileParentBlock($this->compiler);
  1649. }
  1650. }
  1651. #line 550 "../smarty/lexer/smarty_internal_templateparser.y"
  1652. function yy_r54()
  1653. {
  1654. $tag =
  1655. trim(substr($this->yystack[ $this->yyidx + 0 ]->minor, $this->lex->ldel_length, - $this->lex->rdel_length),
  1656. ' /');
  1657. if ($tag == 'strip') {
  1658. $this->strip = false;
  1659. $this->_retvalue = null;
  1660. } else {
  1661. $this->_retvalue = $this->compiler->compileTag($tag . 'close', array());
  1662. }
  1663. }
  1664. #line 559 "../smarty/lexer/smarty_internal_templateparser.y"
  1665. function yy_r55()
  1666. {
  1667. $this->_retvalue = $this->compiler->compileTag($this->yystack[ $this->yyidx + 0 ]->minor . 'close', array());
  1668. }
  1669. #line 563 "../smarty/lexer/smarty_internal_templateparser.y"
  1670. function yy_r56()
  1671. {
  1672. $this->_retvalue = $this->compiler->compileTag($this->yystack[ $this->yyidx + - 1 ]->minor . 'close', array(),
  1673. array('modifier_list' => $this->yystack[ $this->yyidx +
  1674. 0 ]->minor));
  1675. }
  1676. #line 568 "../smarty/lexer/smarty_internal_templateparser.y"
  1677. function yy_r57()
  1678. {
  1679. $this->_retvalue = $this->compiler->compileTag($this->yystack[ $this->yyidx + - 2 ]->minor . 'close', array(),
  1680. array('object_method' => $this->yystack[ $this->yyidx +
  1681. 0 ]->minor));
  1682. }
  1683. #line 572 "../smarty/lexer/smarty_internal_templateparser.y"
  1684. function yy_r58()
  1685. {
  1686. $this->_retvalue = $this->compiler->compileTag($this->yystack[ $this->yyidx + - 3 ]->minor . 'close', array(),
  1687. array('object_method' => $this->yystack[ $this->yyidx +
  1688. - 1 ]->minor, 'modifier_list' => $this->yystack[ $this->yyidx +
  1689. 0 ]->minor));
  1690. }
  1691. #line 580 "../smarty/lexer/smarty_internal_templateparser.y"
  1692. function yy_r59()
  1693. {
  1694. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor;
  1695. $this->_retvalue[] = $this->yystack[ $this->yyidx + 0 ]->minor;
  1696. }
  1697. #line 586 "../smarty/lexer/smarty_internal_templateparser.y"
  1698. function yy_r60()
  1699. {
  1700. $this->_retvalue = array($this->yystack[ $this->yyidx + 0 ]->minor);
  1701. }
  1702. #line 591 "../smarty/lexer/smarty_internal_templateparser.y"
  1703. function yy_r61()
  1704. {
  1705. $this->_retvalue = array();
  1706. }
  1707. #line 596 "../smarty/lexer/smarty_internal_templateparser.y"
  1708. function yy_r62()
  1709. {
  1710. if (defined($this->yystack[ $this->yyidx + 0 ]->minor)) {
  1711. if ($this->security) {
  1712. $this->security->isTrustedConstant($this->yystack[ $this->yyidx + 0 ]->minor, $this->compiler);
  1713. }
  1714. $this->_retvalue =
  1715. array($this->yystack[ $this->yyidx + - 2 ]->minor => $this->yystack[ $this->yyidx + 0 ]->minor);
  1716. } else {
  1717. $this->_retvalue =
  1718. array($this->yystack[ $this->yyidx + - 2 ]->minor => '\'' . $this->yystack[ $this->yyidx + 0 ]->minor .
  1719. '\'');
  1720. }
  1721. }
  1722. #line 607 "../smarty/lexer/smarty_internal_templateparser.y"
  1723. function yy_r63()
  1724. {
  1725. $this->_retvalue =
  1726. array(trim($this->yystack[ $this->yyidx + - 1 ]->minor, " =\n\r\t") => $this->yystack[ $this->yyidx +
  1727. 0 ]->minor);
  1728. }
  1729. #line 615 "../smarty/lexer/smarty_internal_templateparser.y"
  1730. function yy_r65()
  1731. {
  1732. $this->_retvalue = '\'' . $this->yystack[ $this->yyidx + 0 ]->minor . '\'';
  1733. }
  1734. #line 627 "../smarty/lexer/smarty_internal_templateparser.y"
  1735. function yy_r68()
  1736. {
  1737. $this->_retvalue =
  1738. array($this->yystack[ $this->yyidx + - 2 ]->minor => $this->yystack[ $this->yyidx + 0 ]->minor);
  1739. }
  1740. #line 640 "../smarty/lexer/smarty_internal_templateparser.y"
  1741. function yy_r70()
  1742. {
  1743. $this->yystack[ $this->yyidx + - 2 ]->minor[] = $this->yystack[ $this->yyidx + 0 ]->minor;
  1744. $this->_retvalue = $this->yystack[ $this->yyidx + - 2 ]->minor;
  1745. }
  1746. #line 645 "../smarty/lexer/smarty_internal_templateparser.y"
  1747. function yy_r71()
  1748. {
  1749. $this->_retvalue = array('var' => '\'' . substr($this->yystack[ $this->yyidx + - 2 ]->minor, 1) . '\'',
  1750. 'value' => $this->yystack[ $this->yyidx + 0 ]->minor);
  1751. }
  1752. #line 652 "../smarty/lexer/smarty_internal_templateparser.y"
  1753. function yy_r73()
  1754. {
  1755. $this->_retvalue = array('var' => $this->yystack[ $this->yyidx + - 2 ]->minor,
  1756. 'value' => $this->yystack[ $this->yyidx + 0 ]->minor);
  1757. }
  1758. #line 676 "../smarty/lexer/smarty_internal_templateparser.y"
  1759. function yy_r77()
  1760. {
  1761. $this->_retvalue =
  1762. '$_smarty_tpl->getStreamVariable(\'' . substr($this->yystack[ $this->yyidx + - 2 ]->minor, 1) . '://' .
  1763. $this->yystack[ $this->yyidx + 0 ]->minor . '\')';
  1764. }
  1765. #line 681 "../smarty/lexer/smarty_internal_templateparser.y"
  1766. function yy_r78()
  1767. {
  1768. $this->_retvalue =
  1769. $this->yystack[ $this->yyidx + - 2 ]->minor . trim($this->yystack[ $this->yyidx + - 1 ]->minor) .
  1770. $this->yystack[ $this->yyidx + 0 ]->minor;
  1771. }
  1772. #line 695 "../smarty/lexer/smarty_internal_templateparser.y"
  1773. function yy_r81()
  1774. {
  1775. $this->_retvalue = $this->compiler->compileTag('private_modifier', array(),
  1776. array('value' => $this->yystack[ $this->yyidx + - 1 ]->minor,
  1777. 'modifierlist' => $this->yystack[ $this->yyidx +
  1778. 0 ]->minor));
  1779. }
  1780. #line 701 "../smarty/lexer/smarty_internal_templateparser.y"
  1781. function yy_r82()
  1782. {
  1783. $this->_retvalue = (isset($this->yystack[ $this->yyidx + - 1 ]->minor[ 'pre' ]) ?
  1784. $this->yystack[ $this->yyidx + - 1 ]->minor[ 'pre' ] : '') .
  1785. $this->yystack[ $this->yyidx + - 2 ]->minor . $this->yystack[ $this->yyidx + - 1 ]->minor[ 'op' ] .
  1786. $this->yystack[ $this->yyidx + 0 ]->minor .
  1787. (isset($this->yystack[ $this->yyidx + - 1 ]->minor[ 'pre' ]) ? ')' : '');
  1788. }
  1789. #line 704 "../smarty/lexer/smarty_internal_templateparser.y"
  1790. function yy_r83()
  1791. {
  1792. $this->_retvalue =
  1793. $this->yystack[ $this->yyidx + 0 ]->minor . $this->yystack[ $this->yyidx + - 1 ]->minor . ')';
  1794. }
  1795. #line 708 "../smarty/lexer/smarty_internal_templateparser.y"
  1796. function yy_r84()
  1797. {
  1798. $this->_retvalue = 'in_array(' . $this->yystack[ $this->yyidx + - 2 ]->minor . ',' .
  1799. $this->yystack[ $this->yyidx + 0 ]->minor . ')';
  1800. }
  1801. #line 712 "../smarty/lexer/smarty_internal_templateparser.y"
  1802. function yy_r85()
  1803. {
  1804. $this->_retvalue = 'in_array(' . $this->yystack[ $this->yyidx + - 2 ]->minor . ',(array)' .
  1805. $this->yystack[ $this->yyidx + 0 ]->minor . ')';
  1806. }
  1807. #line 716 "../smarty/lexer/smarty_internal_templateparser.y"
  1808. function yy_r86()
  1809. {
  1810. $this->_retvalue = $this->yystack[ $this->yyidx + - 2 ]->minor . $this->yystack[ $this->yyidx + - 1 ]->minor .
  1811. $this->yystack[ $this->yyidx + 0 ]->minor;
  1812. }
  1813. #line 728 "../smarty/lexer/smarty_internal_templateparser.y"
  1814. function yy_r88()
  1815. {
  1816. $this->_retvalue = $this->yystack[ $this->yyidx + - 5 ]->minor . ' ? ' .
  1817. $this->compiler->compileVariable('\'' . substr($this->yystack[ $this->yyidx + - 2 ]->minor, 1) . '\'') .
  1818. ' : ' . $this->yystack[ $this->yyidx + 0 ]->minor;
  1819. }
  1820. #line 732 "../smarty/lexer/smarty_internal_templateparser.y"
  1821. function yy_r89()
  1822. {
  1823. $this->_retvalue =
  1824. $this->yystack[ $this->yyidx + - 5 ]->minor . ' ? ' . $this->yystack[ $this->yyidx + - 2 ]->minor . ' : ' .
  1825. $this->yystack[ $this->yyidx + 0 ]->minor;
  1826. }
  1827. #line 747 "../smarty/lexer/smarty_internal_templateparser.y"
  1828. function yy_r92()
  1829. {
  1830. $this->_retvalue = '!' . $this->yystack[ $this->yyidx + 0 ]->minor;
  1831. }
  1832. #line 768 "../smarty/lexer/smarty_internal_templateparser.y"
  1833. function yy_r97()
  1834. {
  1835. $this->_retvalue =
  1836. $this->yystack[ $this->yyidx + - 2 ]->minor . '.' . $this->yystack[ $this->yyidx + 0 ]->minor;
  1837. }
  1838. #line 772 "../smarty/lexer/smarty_internal_templateparser.y"
  1839. function yy_r98()
  1840. {
  1841. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor . '.';
  1842. }
  1843. #line 776 "../smarty/lexer/smarty_internal_templateparser.y"
  1844. function yy_r99()
  1845. {
  1846. $this->_retvalue = '.' . $this->yystack[ $this->yyidx + 0 ]->minor;
  1847. }
  1848. #line 781 "../smarty/lexer/smarty_internal_templateparser.y"
  1849. function yy_r100()
  1850. {
  1851. if (defined($this->yystack[ $this->yyidx + 0 ]->minor)) {
  1852. if ($this->security) {
  1853. $this->security->isTrustedConstant($this->yystack[ $this->yyidx + 0 ]->minor, $this->compiler);
  1854. }
  1855. $this->_retvalue = $this->yystack[ $this->yyidx + 0 ]->minor;
  1856. } else {
  1857. $this->_retvalue = '\'' . $this->yystack[ $this->yyidx + 0 ]->minor . '\'';
  1858. }
  1859. }
  1860. #line 798 "../smarty/lexer/smarty_internal_templateparser.y"
  1861. function yy_r102()
  1862. {
  1863. $this->_retvalue = "(" . $this->yystack[ $this->yyidx + - 1 ]->minor . ")";
  1864. }
  1865. #line 813 "../smarty/lexer/smarty_internal_templateparser.y"
  1866. function yy_r105()
  1867. {
  1868. self::$prefix_number ++;
  1869. if ($this->yystack[ $this->yyidx + - 2 ]->minor[ 'var' ] == '\'smarty\'') {
  1870. $this->compiler->prefix_code[] = '<?php $_tmp' . self::$prefix_number . ' = ' .
  1871. $this->compiler->compileTag('private_special_variable', array(),
  1872. $this->yystack[ $this->yyidx + - 2 ]->minor[ 'smarty_internal_index' ]) .
  1873. ';?>';
  1874. } else {
  1875. $this->compiler->prefix_code[] = '<?php $_tmp' . self::$prefix_number . ' = ' .
  1876. $this->compiler->compileVariable($this->yystack[ $this->yyidx + - 2 ]->minor[ 'var' ]) .
  1877. $this->yystack[ $this->yyidx + - 2 ]->minor[ 'smarty_internal_index' ] . ';?>';
  1878. }
  1879. $this->_retvalue = '$_tmp' . self::$prefix_number . '::' . $this->yystack[ $this->yyidx + 0 ]->minor[ 0 ] .
  1880. $this->yystack[ $this->yyidx + 0 ]->minor[ 1 ];
  1881. }
  1882. #line 824 "../smarty/lexer/smarty_internal_templateparser.y"
  1883. function yy_r106()
  1884. {
  1885. self::$prefix_number ++;
  1886. $tmp = $this->compiler->appendCode('<?php ob_start();?>', $this->yystack[ $this->yyidx + 0 ]->minor);
  1887. $this->compiler->prefix_code[] =
  1888. $this->compiler->appendCode($tmp, '<?php $_tmp' . self::$prefix_number . '=ob_get_clean();?>');
  1889. $this->_retvalue = '$_tmp' . self::$prefix_number;
  1890. }
  1891. #line 841 "../smarty/lexer/smarty_internal_templateparser.y"
  1892. function yy_r109()
  1893. {
  1894. if (!in_array(strtolower($this->yystack[ $this->yyidx + - 2 ]->minor), array('self', 'parent')) &&
  1895. (!$this->security ||
  1896. $this->security->isTrustedStaticClassAccess($this->yystack[ $this->yyidx + - 2 ]->minor,
  1897. $this->yystack[ $this->yyidx + 0 ]->minor, $this->compiler))
  1898. ) {
  1899. if (isset($this->smarty->registered_classes[ $this->yystack[ $this->yyidx + - 2 ]->minor ])) {
  1900. $this->_retvalue =
  1901. $this->smarty->registered_classes[ $this->yystack[ $this->yyidx + - 2 ]->minor ] . '::' .
  1902. $this->yystack[ $this->yyidx + 0 ]->minor[ 0 ] . $this->yystack[ $this->yyidx + 0 ]->minor[ 1 ];
  1903. } else {
  1904. $this->_retvalue = $this->yystack[ $this->yyidx + - 2 ]->minor . '::' .
  1905. $this->yystack[ $this->yyidx + 0 ]->minor[ 0 ] . $this->yystack[ $this->yyidx + 0 ]->minor[ 1 ];
  1906. }
  1907. } else {
  1908. $this->compiler->trigger_template_error("static class '" . $this->yystack[ $this->yyidx + - 2 ]->minor .
  1909. "' is undefined or not allowed by security setting");
  1910. }
  1911. }
  1912. #line 860 "../smarty/lexer/smarty_internal_templateparser.y"
  1913. function yy_r111()
  1914. {
  1915. $this->_retvalue = $this->yystack[ $this->yyidx + 0 ]->minor;
  1916. }
  1917. #line 871 "../smarty/lexer/smarty_internal_templateparser.y"
  1918. function yy_r112()
  1919. {
  1920. $this->_retvalue =
  1921. $this->compiler->compileVariable('\'' . substr($this->yystack[ $this->yyidx + 0 ]->minor, 1) . '\'');
  1922. }
  1923. #line 874 "../smarty/lexer/smarty_internal_templateparser.y"
  1924. function yy_r113()
  1925. {
  1926. if ($this->yystack[ $this->yyidx + 0 ]->minor[ 'var' ] == '\'smarty\'') {
  1927. $smarty_var = $this->compiler->compileTag('private_special_variable', array(),
  1928. $this->yystack[ $this->yyidx +
  1929. 0 ]->minor[ 'smarty_internal_index' ]);
  1930. $this->_retvalue = $smarty_var;
  1931. } else {
  1932. // used for array reset,next,prev,end,current
  1933. $this->last_variable = $this->yystack[ $this->yyidx + 0 ]->minor[ 'var' ];
  1934. $this->last_index = $this->yystack[ $this->yyidx + 0 ]->minor[ 'smarty_internal_index' ];
  1935. $this->_retvalue = $this->compiler->compileVariable($this->yystack[ $this->yyidx + 0 ]->minor[ 'var' ]) .
  1936. $this->yystack[ $this->yyidx + 0 ]->minor[ 'smarty_internal_index' ];
  1937. }
  1938. }
  1939. #line 887 "../smarty/lexer/smarty_internal_templateparser.y"
  1940. function yy_r114()
  1941. {
  1942. $this->_retvalue = '$_smarty_tpl->tpl_vars[' . $this->yystack[ $this->yyidx + - 2 ]->minor . ']->' .
  1943. $this->yystack[ $this->yyidx + 0 ]->minor;
  1944. }
  1945. #line 897 "../smarty/lexer/smarty_internal_templateparser.y"
  1946. function yy_r116()
  1947. {
  1948. $this->_retvalue =
  1949. $this->compiler->compileConfigVariable("'" . $this->yystack[ $this->yyidx + - 1 ]->minor . "'");
  1950. }
  1951. #line 901 "../smarty/lexer/smarty_internal_templateparser.y"
  1952. function yy_r117()
  1953. {
  1954. $this->_retvalue = '(is_array($tmp = ' .
  1955. $this->compiler->compileConfigVariable("'" . $this->yystack[ $this->yyidx + - 2 ]->minor . "'") .
  1956. ') ? $tmp' . $this->yystack[ $this->yyidx + 0 ]->minor . ' :null)';
  1957. }
  1958. #line 905 "../smarty/lexer/smarty_internal_templateparser.y"
  1959. function yy_r118()
  1960. {
  1961. $this->_retvalue = $this->compiler->compileConfigVariable($this->yystack[ $this->yyidx + - 1 ]->minor);
  1962. }
  1963. #line 909 "../smarty/lexer/smarty_internal_templateparser.y"
  1964. function yy_r119()
  1965. {
  1966. $this->_retvalue =
  1967. '(is_array($tmp = ' . $this->compiler->compileConfigVariable($this->yystack[ $this->yyidx + - 2 ]->minor) .
  1968. ') ? $tmp' . $this->yystack[ $this->yyidx + 0 ]->minor . ' : null)';
  1969. }
  1970. #line 913 "../smarty/lexer/smarty_internal_templateparser.y"
  1971. function yy_r120()
  1972. {
  1973. $this->_retvalue = array('var' => '\'' . substr($this->yystack[ $this->yyidx + - 1 ]->minor, 1) . '\'',
  1974. 'smarty_internal_index' => $this->yystack[ $this->yyidx + 0 ]->minor);
  1975. }
  1976. #line 916 "../smarty/lexer/smarty_internal_templateparser.y"
  1977. function yy_r121()
  1978. {
  1979. $this->_retvalue = array('var' => $this->yystack[ $this->yyidx + - 1 ]->minor,
  1980. 'smarty_internal_index' => $this->yystack[ $this->yyidx + 0 ]->minor);
  1981. }
  1982. #line 929 "../smarty/lexer/smarty_internal_templateparser.y"
  1983. function yy_r123()
  1984. {
  1985. return;
  1986. }
  1987. #line 935 "../smarty/lexer/smarty_internal_templateparser.y"
  1988. function yy_r124()
  1989. {
  1990. $this->_retvalue =
  1991. '[' . $this->compiler->compileVariable('\'' . substr($this->yystack[ $this->yyidx + 0 ]->minor, 1) . '\'') .
  1992. ']';
  1993. }
  1994. #line 938 "../smarty/lexer/smarty_internal_templateparser.y"
  1995. function yy_r125()
  1996. {
  1997. $this->_retvalue = '[' . $this->compiler->compileVariable($this->yystack[ $this->yyidx + 0 ]->minor) . ']';
  1998. }
  1999. #line 942 "../smarty/lexer/smarty_internal_templateparser.y"
  2000. function yy_r126()
  2001. {
  2002. $this->_retvalue = '[' . $this->compiler->compileVariable($this->yystack[ $this->yyidx + - 2 ]->minor) . '->' .
  2003. $this->yystack[ $this->yyidx + 0 ]->minor . ']';
  2004. }
  2005. #line 946 "../smarty/lexer/smarty_internal_templateparser.y"
  2006. function yy_r127()
  2007. {
  2008. if (defined($this->yystack[ $this->yyidx + 0 ]->minor)) {
  2009. if ($this->security) {
  2010. $this->security->isTrustedConstant($this->yystack[ $this->yyidx + 0 ]->minor, $this->compiler);
  2011. }
  2012. $this->_retvalue = '[' . $this->yystack[ $this->yyidx + 0 ]->minor . ']';
  2013. } else {
  2014. $this->_retvalue = "['" . $this->yystack[ $this->yyidx + 0 ]->minor . "']";
  2015. }
  2016. }
  2017. #line 957 "../smarty/lexer/smarty_internal_templateparser.y"
  2018. function yy_r128()
  2019. {
  2020. $this->_retvalue = '[' . $this->yystack[ $this->yyidx + 0 ]->minor . ']';
  2021. }
  2022. #line 962 "../smarty/lexer/smarty_internal_templateparser.y"
  2023. function yy_r129()
  2024. {
  2025. $this->_retvalue = '[' . $this->yystack[ $this->yyidx + - 1 ]->minor . ']';
  2026. }
  2027. #line 967 "../smarty/lexer/smarty_internal_templateparser.y"
  2028. function yy_r130()
  2029. {
  2030. $this->_retvalue = '[' . $this->compiler->compileTag('private_special_variable', array(), '[\'section\'][\'' .
  2031. $this->yystack[ $this->yyidx +
  2032. - 1 ]->minor .
  2033. '\'][\'index\']') . ']';
  2034. }
  2035. #line 971 "../smarty/lexer/smarty_internal_templateparser.y"
  2036. function yy_r131()
  2037. {
  2038. $this->_retvalue = '[' . $this->compiler->compileTag('private_special_variable', array(), '[\'section\'][\'' .
  2039. $this->yystack[ $this->yyidx +
  2040. - 3 ]->minor . '\'][\'' .
  2041. $this->yystack[ $this->yyidx +
  2042. - 1 ]->minor . '\']') . ']';
  2043. }
  2044. #line 974 "../smarty/lexer/smarty_internal_templateparser.y"
  2045. function yy_r132()
  2046. {
  2047. $this->_retvalue = '[' . $this->yystack[ $this->yyidx + - 1 ]->minor . ']';
  2048. }
  2049. #line 980 "../smarty/lexer/smarty_internal_templateparser.y"
  2050. function yy_r134()
  2051. {
  2052. $this->_retvalue = '[' .
  2053. $this->compiler->compileVariable('\'' . substr($this->yystack[ $this->yyidx + - 1 ]->minor, 1) . '\'') .
  2054. ']';;
  2055. }
  2056. #line 996 "../smarty/lexer/smarty_internal_templateparser.y"
  2057. function yy_r138()
  2058. {
  2059. $this->_retvalue = '[]';
  2060. }
  2061. #line 1006 "../smarty/lexer/smarty_internal_templateparser.y"
  2062. function yy_r139()
  2063. {
  2064. $this->_retvalue = '\'' . substr($this->yystack[ $this->yyidx + 0 ]->minor, 1) . '\'';
  2065. }
  2066. #line 1010 "../smarty/lexer/smarty_internal_templateparser.y"
  2067. function yy_r140()
  2068. {
  2069. $this->_retvalue = "''";
  2070. }
  2071. #line 1015 "../smarty/lexer/smarty_internal_templateparser.y"
  2072. function yy_r141()
  2073. {
  2074. $this->_retvalue =
  2075. $this->yystack[ $this->yyidx + - 1 ]->minor . '.' . $this->yystack[ $this->yyidx + 0 ]->minor;
  2076. }
  2077. #line 1023 "../smarty/lexer/smarty_internal_templateparser.y"
  2078. function yy_r143()
  2079. {
  2080. $var =
  2081. trim(substr($this->yystack[ $this->yyidx + 0 ]->minor, $this->lex->ldel_length, - $this->lex->rdel_length),
  2082. ' $');
  2083. $this->_retvalue = $this->compiler->compileVariable('\'' . $var . '\'');
  2084. }
  2085. #line 1029 "../smarty/lexer/smarty_internal_templateparser.y"
  2086. function yy_r144()
  2087. {
  2088. $this->_retvalue = '(' . $this->yystack[ $this->yyidx + - 1 ]->minor . ')';
  2089. }
  2090. #line 1036 "../smarty/lexer/smarty_internal_templateparser.y"
  2091. function yy_r145()
  2092. {
  2093. if ($this->yystack[ $this->yyidx + - 1 ]->minor[ 'var' ] == '\'smarty\'') {
  2094. $this->_retvalue = $this->compiler->compileTag('private_special_variable', array(),
  2095. $this->yystack[ $this->yyidx +
  2096. - 1 ]->minor[ 'smarty_internal_index' ]) .
  2097. $this->yystack[ $this->yyidx + 0 ]->minor;
  2098. } else {
  2099. $this->_retvalue = $this->compiler->compileVariable($this->yystack[ $this->yyidx + - 1 ]->minor[ 'var' ]) .
  2100. $this->yystack[ $this->yyidx + - 1 ]->minor[ 'smarty_internal_index' ] .
  2101. $this->yystack[ $this->yyidx + 0 ]->minor;
  2102. }
  2103. }
  2104. #line 1045 "../smarty/lexer/smarty_internal_templateparser.y"
  2105. function yy_r146()
  2106. {
  2107. $this->_retvalue = $this->yystack[ $this->yyidx + 0 ]->minor;
  2108. }
  2109. #line 1050 "../smarty/lexer/smarty_internal_templateparser.y"
  2110. function yy_r147()
  2111. {
  2112. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor . $this->yystack[ $this->yyidx + 0 ]->minor;
  2113. }
  2114. #line 1055 "../smarty/lexer/smarty_internal_templateparser.y"
  2115. function yy_r148()
  2116. {
  2117. if ($this->security && substr($this->yystack[ $this->yyidx + - 1 ]->minor, 0, 1) == '_') {
  2118. $this->compiler->trigger_template_error(self::Err1);
  2119. }
  2120. $this->_retvalue =
  2121. '->' . $this->yystack[ $this->yyidx + - 1 ]->minor . $this->yystack[ $this->yyidx + 0 ]->minor;
  2122. }
  2123. #line 1062 "../smarty/lexer/smarty_internal_templateparser.y"
  2124. function yy_r149()
  2125. {
  2126. if ($this->security) {
  2127. $this->compiler->trigger_template_error(self::Err2);
  2128. }
  2129. $this->_retvalue = '->{' . $this->compiler->compileVariable($this->yystack[ $this->yyidx + - 1 ]->minor) .
  2130. $this->yystack[ $this->yyidx + 0 ]->minor . '}';
  2131. }
  2132. #line 1069 "../smarty/lexer/smarty_internal_templateparser.y"
  2133. function yy_r150()
  2134. {
  2135. if ($this->security) {
  2136. $this->compiler->trigger_template_error(self::Err2);
  2137. }
  2138. $this->_retvalue =
  2139. '->{' . $this->yystack[ $this->yyidx + - 2 ]->minor . $this->yystack[ $this->yyidx + 0 ]->minor . '}';
  2140. }
  2141. #line 1076 "../smarty/lexer/smarty_internal_templateparser.y"
  2142. function yy_r151()
  2143. {
  2144. if ($this->security) {
  2145. $this->compiler->trigger_template_error(self::Err2);
  2146. }
  2147. $this->_retvalue = '->{\'' . $this->yystack[ $this->yyidx + - 4 ]->minor . '\'.' .
  2148. $this->yystack[ $this->yyidx + - 2 ]->minor . $this->yystack[ $this->yyidx + 0 ]->minor . '}';
  2149. }
  2150. #line 1084 "../smarty/lexer/smarty_internal_templateparser.y"
  2151. function yy_r152()
  2152. {
  2153. $this->_retvalue = '->' . $this->yystack[ $this->yyidx + 0 ]->minor;
  2154. }
  2155. #line 1092 "../smarty/lexer/smarty_internal_templateparser.y"
  2156. function yy_r153()
  2157. {
  2158. if (!$this->security ||
  2159. $this->security->isTrustedPhpFunction($this->yystack[ $this->yyidx + - 3 ]->minor, $this->compiler)
  2160. ) {
  2161. if (strcasecmp($this->yystack[ $this->yyidx + - 3 ]->minor, 'isset') === 0 ||
  2162. strcasecmp($this->yystack[ $this->yyidx + - 3 ]->minor, 'empty') === 0 ||
  2163. strcasecmp($this->yystack[ $this->yyidx + - 3 ]->minor, 'array') === 0 ||
  2164. is_callable($this->yystack[ $this->yyidx + - 3 ]->minor)
  2165. ) {
  2166. $func_name = strtolower($this->yystack[ $this->yyidx + - 3 ]->minor);
  2167. if ($func_name == 'isset') {
  2168. if (count($this->yystack[ $this->yyidx + - 1 ]->minor) == 0) {
  2169. $this->compiler->trigger_template_error('Illegal number of paramer in "isset()"');
  2170. }
  2171. $par = implode(',', $this->yystack[ $this->yyidx + - 1 ]->minor);
  2172. if (strncasecmp($par, '$_smarty_tpl->smarty->ext->_config->_getConfigVariable',
  2173. strlen('$_smarty_tpl->smarty->ext->_config->_getConfigVariable')) === 0
  2174. ) {
  2175. self::$prefix_number ++;
  2176. $this->compiler->prefix_code[] =
  2177. '<?php $_tmp' . self::$prefix_number . '=' . str_replace(')', ', false)', $par) . ';?>';
  2178. $isset_par = '$_tmp' . self::$prefix_number;
  2179. } else {
  2180. $isset_par = str_replace("')->value", "',null,true,false)->value", $par);
  2181. }
  2182. $this->_retvalue = $this->yystack[ $this->yyidx + - 3 ]->minor . "(" . $isset_par . ")";
  2183. } elseif (in_array($func_name, array('empty', 'reset', 'current', 'end', 'prev', 'next'))) {
  2184. if (count($this->yystack[ $this->yyidx + - 1 ]->minor) != 1) {
  2185. $this->compiler->trigger_template_error('Illegal number of paramer in "empty()"');
  2186. }
  2187. if ($func_name == 'empty') {
  2188. $this->_retvalue = $func_name . '(' . str_replace("')->value", "',null,true,false)->value",
  2189. $this->yystack[ $this->yyidx +
  2190. - 1 ]->minor[ 0 ]) . ')';
  2191. } else {
  2192. $this->_retvalue = $func_name . '(' . $this->yystack[ $this->yyidx + - 1 ]->minor[ 0 ] . ')';
  2193. }
  2194. } else {
  2195. $this->_retvalue = $this->yystack[ $this->yyidx + - 3 ]->minor . "(" .
  2196. implode(',', $this->yystack[ $this->yyidx + - 1 ]->minor) . ")";
  2197. }
  2198. } else {
  2199. $this->compiler->trigger_template_error("unknown function \"" .
  2200. $this->yystack[ $this->yyidx + - 3 ]->minor . "\"");
  2201. }
  2202. }
  2203. }
  2204. #line 1131 "../smarty/lexer/smarty_internal_templateparser.y"
  2205. function yy_r154()
  2206. {
  2207. if ($this->security && substr($this->yystack[ $this->yyidx + - 3 ]->minor, 0, 1) == '_') {
  2208. $this->compiler->trigger_template_error(self::Err1);
  2209. }
  2210. $this->_retvalue = $this->yystack[ $this->yyidx + - 3 ]->minor . "(" .
  2211. implode(',', $this->yystack[ $this->yyidx + - 1 ]->minor) . ")";
  2212. }
  2213. #line 1138 "../smarty/lexer/smarty_internal_templateparser.y"
  2214. function yy_r155()
  2215. {
  2216. if ($this->security) {
  2217. $this->compiler->trigger_template_error(self::Err2);
  2218. }
  2219. self::$prefix_number ++;
  2220. $this->compiler->prefix_code[] = '<?php $_tmp' . self::$prefix_number . '=' .
  2221. $this->compiler->compileVariable('\'' . substr($this->yystack[ $this->yyidx + - 3 ]->minor, 1) . '\'') .
  2222. ';?>';
  2223. $this->_retvalue =
  2224. '$_tmp' . self::$prefix_number . '(' . implode(',', $this->yystack[ $this->yyidx + - 1 ]->minor) . ')';
  2225. }
  2226. #line 1149 "../smarty/lexer/smarty_internal_templateparser.y"
  2227. function yy_r156()
  2228. {
  2229. $this->_retvalue =
  2230. array_merge($this->yystack[ $this->yyidx + - 2 ]->minor, array($this->yystack[ $this->yyidx + 0 ]->minor));
  2231. }
  2232. #line 1166 "../smarty/lexer/smarty_internal_templateparser.y"
  2233. function yy_r159()
  2234. {
  2235. $this->_retvalue = array_merge($this->yystack[ $this->yyidx + - 2 ]->minor,
  2236. array(array_merge($this->yystack[ $this->yyidx + - 1 ]->minor,
  2237. $this->yystack[ $this->yyidx + 0 ]->minor)));
  2238. }
  2239. #line 1170 "../smarty/lexer/smarty_internal_templateparser.y"
  2240. function yy_r160()
  2241. {
  2242. $this->_retvalue =
  2243. array(array_merge($this->yystack[ $this->yyidx + - 1 ]->minor, $this->yystack[ $this->yyidx + 0 ]->minor));
  2244. }
  2245. #line 1178 "../smarty/lexer/smarty_internal_templateparser.y"
  2246. function yy_r162()
  2247. {
  2248. $this->_retvalue = array($this->yystack[ $this->yyidx + 0 ]->minor);
  2249. }
  2250. #line 1186 "../smarty/lexer/smarty_internal_templateparser.y"
  2251. function yy_r163()
  2252. {
  2253. $this->_retvalue =
  2254. array_merge($this->yystack[ $this->yyidx + - 1 ]->minor, $this->yystack[ $this->yyidx + 0 ]->minor);
  2255. }
  2256. #line 1205 "../smarty/lexer/smarty_internal_templateparser.y"
  2257. function yy_r167()
  2258. {
  2259. $this->_retvalue = array($this->yystack[ $this->yyidx + 0 ]->minor, '', 'method');
  2260. }
  2261. #line 1210 "../smarty/lexer/smarty_internal_templateparser.y"
  2262. function yy_r168()
  2263. {
  2264. $this->_retvalue =
  2265. array($this->yystack[ $this->yyidx + - 1 ]->minor, $this->yystack[ $this->yyidx + 0 ]->minor, 'method');
  2266. }
  2267. #line 1215 "../smarty/lexer/smarty_internal_templateparser.y"
  2268. function yy_r169()
  2269. {
  2270. $this->_retvalue = array($this->yystack[ $this->yyidx + 0 ]->minor, '');
  2271. }
  2272. #line 1220 "../smarty/lexer/smarty_internal_templateparser.y"
  2273. function yy_r170()
  2274. {
  2275. $this->_retvalue =
  2276. array($this->yystack[ $this->yyidx + - 1 ]->minor, $this->yystack[ $this->yyidx + 0 ]->minor, 'property');
  2277. }
  2278. #line 1225 "../smarty/lexer/smarty_internal_templateparser.y"
  2279. function yy_r171()
  2280. {
  2281. $this->_retvalue = array($this->yystack[ $this->yyidx + - 2 ]->minor,
  2282. $this->yystack[ $this->yyidx + - 1 ]->minor .
  2283. $this->yystack[ $this->yyidx + 0 ]->minor, 'property');
  2284. }
  2285. #line 1231 "../smarty/lexer/smarty_internal_templateparser.y"
  2286. function yy_r172()
  2287. {
  2288. $this->_retvalue[ 'op' ] = ' ' . trim($this->yystack[ $this->yyidx + 0 ]->minor) . ' ';
  2289. }
  2290. #line 1235 "../smarty/lexer/smarty_internal_templateparser.y"
  2291. function yy_r173()
  2292. {
  2293. static $lops = array('eq' => array('op' => ' == ', 'pre' => null),
  2294. 'ne' => array('op' => ' != ', 'pre' => null),
  2295. 'neq' => array('op' => ' != ', 'pre' => null),
  2296. 'gt' => array('op' => ' > ', 'pre' => null),
  2297. 'ge' => array('op' => ' >= ', 'pre' => null),
  2298. 'gte' => array('op' => ' >= ', 'pre' => null),
  2299. 'lt' => array('op' => ' < ', 'pre' => null),
  2300. 'le' => array('op' => ' <= ', 'pre' => null),
  2301. 'lte' => array('op' => ' <= ', 'pre' => null),
  2302. 'mod' => array('op' => ' % ', 'pre' => null),
  2303. 'and' => array('op' => ' && ', 'pre' => null),
  2304. 'or' => array('op' => ' || ', 'pre' => null),
  2305. 'xor' => array('op' => ' xor ', 'pre' => null),
  2306. 'isdivby' => array('op' => ' % ', 'pre' => '!('),
  2307. 'isnotdivby' => array('op' => ' % ', 'pre' => '('),
  2308. 'isevenby' => array('op' => ' / ', 'pre' => '!(1 & '),
  2309. 'isnotevenby' => array('op' => ' / ', 'pre' => '(1 & '),
  2310. 'isoddby' => array('op' => ' / ', 'pre' => '(1 & '),
  2311. 'isnotoddby' => array('op' => ' / ', 'pre' => '!(1 & '),);
  2312. $op = strtolower(preg_replace('/\s*/', '', $this->yystack[ $this->yyidx + 0 ]->minor));
  2313. $this->_retvalue = $lops[ $op ];
  2314. }
  2315. #line 1261 "../smarty/lexer/smarty_internal_templateparser.y"
  2316. function yy_r174()
  2317. {
  2318. static $scond =
  2319. array('iseven' => '!(1 & ', 'isnoteven' => '(1 & ', 'isodd' => '(1 & ', 'isnotodd' => '!(1 & ',);
  2320. $op = strtolower(str_replace(' ', '', $this->yystack[ $this->yyidx + 0 ]->minor));
  2321. $this->_retvalue = $scond[ $op ];
  2322. }
  2323. #line 1275 "../smarty/lexer/smarty_internal_templateparser.y"
  2324. function yy_r175()
  2325. {
  2326. $this->_retvalue = 'array(' . $this->yystack[ $this->yyidx + - 1 ]->minor . ')';
  2327. }
  2328. #line 1283 "../smarty/lexer/smarty_internal_templateparser.y"
  2329. function yy_r177()
  2330. {
  2331. $this->_retvalue =
  2332. $this->yystack[ $this->yyidx + - 2 ]->minor . ',' . $this->yystack[ $this->yyidx + 0 ]->minor;
  2333. }
  2334. #line 1291 "../smarty/lexer/smarty_internal_templateparser.y"
  2335. function yy_r179()
  2336. {
  2337. $this->_retvalue =
  2338. $this->yystack[ $this->yyidx + - 2 ]->minor . '=>' . $this->yystack[ $this->yyidx + 0 ]->minor;
  2339. }
  2340. #line 1295 "../smarty/lexer/smarty_internal_templateparser.y"
  2341. function yy_r180()
  2342. {
  2343. $this->_retvalue =
  2344. '\'' . $this->yystack[ $this->yyidx + - 2 ]->minor . '\'=>' . $this->yystack[ $this->yyidx + 0 ]->minor;
  2345. }
  2346. #line 1311 "../smarty/lexer/smarty_internal_templateparser.y"
  2347. function yy_r183()
  2348. {
  2349. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor->to_smarty_php($this);
  2350. }
  2351. #line 1316 "../smarty/lexer/smarty_internal_templateparser.y"
  2352. function yy_r184()
  2353. {
  2354. $this->yystack[ $this->yyidx + - 1 ]->minor->append_subtree($this, $this->yystack[ $this->yyidx + 0 ]->minor);
  2355. $this->_retvalue = $this->yystack[ $this->yyidx + - 1 ]->minor;
  2356. }
  2357. #line 1321 "../smarty/lexer/smarty_internal_templateparser.y"
  2358. function yy_r185()
  2359. {
  2360. $this->_retvalue = new Smarty_Internal_ParseTree_Dq($this, $this->yystack[ $this->yyidx + 0 ]->minor);
  2361. }
  2362. #line 1325 "../smarty/lexer/smarty_internal_templateparser.y"
  2363. function yy_r186()
  2364. {
  2365. $this->_retvalue = new Smarty_Internal_ParseTree_Code('(string)' . $this->yystack[ $this->yyidx + - 1 ]->minor);
  2366. }
  2367. #line 1333 "../smarty/lexer/smarty_internal_templateparser.y"
  2368. function yy_r188()
  2369. {
  2370. $this->_retvalue = new Smarty_Internal_ParseTree_Code('(string)$_smarty_tpl->tpl_vars[\'' .
  2371. substr($this->yystack[ $this->yyidx + 0 ]->minor, 1) .
  2372. '\']->value');
  2373. }
  2374. #line 1341 "../smarty/lexer/smarty_internal_templateparser.y"
  2375. function yy_r190()
  2376. {
  2377. $this->_retvalue =
  2378. new Smarty_Internal_ParseTree_Code('(string)(' . $this->yystack[ $this->yyidx + - 1 ]->minor . ')');
  2379. }
  2380. #line 1345 "../smarty/lexer/smarty_internal_templateparser.y"
  2381. function yy_r191()
  2382. {
  2383. $this->_retvalue = new Smarty_Internal_ParseTree_Tag($this, $this->yystack[ $this->yyidx + 0 ]->minor);
  2384. }
  2385. #line 1349 "../smarty/lexer/smarty_internal_templateparser.y"
  2386. function yy_r192()
  2387. {
  2388. $this->_retvalue = new Smarty_Internal_ParseTree_DqContent($this->yystack[ $this->yyidx + 0 ]->minor);
  2389. }
  2390. private $_retvalue;
  2391. public function yy_reduce($yyruleno)
  2392. {
  2393. if ($this->yyTraceFILE && $yyruleno >= 0 && $yyruleno < count(self::$yyRuleName)) {
  2394. fprintf($this->yyTraceFILE, "%sReduce (%d) [%s].\n", $this->yyTracePrompt, $yyruleno,
  2395. self::$yyRuleName[ $yyruleno ]);
  2396. }
  2397. $this->_retvalue = $yy_lefthand_side = null;
  2398. if (isset(self::$yyReduceMap[ $yyruleno ])) {
  2399. // call the action
  2400. $this->_retvalue = null;
  2401. $this->{'yy_r' . self::$yyReduceMap[ $yyruleno ]}();
  2402. $yy_lefthand_side = $this->_retvalue;
  2403. }
  2404. $yygoto = self::$yyRuleInfo[ $yyruleno ][ 0 ];
  2405. $yysize = self::$yyRuleInfo[ $yyruleno ][ 1 ];
  2406. $this->yyidx -= $yysize;
  2407. for ($i = $yysize; $i; $i --) {
  2408. // pop all of the right-hand side parameters
  2409. array_pop($this->yystack);
  2410. }
  2411. $yyact = $this->yy_find_reduce_action($this->yystack[ $this->yyidx ]->stateno, $yygoto);
  2412. if ($yyact < self::YYNSTATE) {
  2413. if (!$this->yyTraceFILE && $yysize) {
  2414. $this->yyidx ++;
  2415. $x = new TP_yyStackEntry;
  2416. $x->stateno = $yyact;
  2417. $x->major = $yygoto;
  2418. $x->minor = $yy_lefthand_side;
  2419. $this->yystack[ $this->yyidx ] = $x;
  2420. } else {
  2421. $this->yy_shift($yyact, $yygoto, $yy_lefthand_side);
  2422. }
  2423. } elseif ($yyact == self::YYNSTATE + self::YYNRULE + 1) {
  2424. $this->yy_accept();
  2425. }
  2426. }
  2427. public function yy_parse_failed()
  2428. {
  2429. if ($this->yyTraceFILE) {
  2430. fprintf($this->yyTraceFILE, "%sFail!\n", $this->yyTracePrompt);
  2431. }
  2432. while ($this->yyidx >= 0) {
  2433. $this->yy_pop_parser_stack();
  2434. }
  2435. }
  2436. public function yy_syntax_error($yymajor, $TOKEN)
  2437. {
  2438. #line 207 "../smarty/lexer/smarty_internal_templateparser.y"
  2439. $this->internalError = true;
  2440. $this->yymajor = $yymajor;
  2441. $this->compiler->trigger_template_error();
  2442. }
  2443. public function yy_accept()
  2444. {
  2445. if ($this->yyTraceFILE) {
  2446. fprintf($this->yyTraceFILE, "%sAccept!\n", $this->yyTracePrompt);
  2447. }
  2448. while ($this->yyidx >= 0) {
  2449. $this->yy_pop_parser_stack();
  2450. }
  2451. #line 200 "../smarty/lexer/smarty_internal_templateparser.y"
  2452. $this->successful = !$this->internalError;
  2453. $this->internalError = false;
  2454. $this->retvalue = $this->_retvalue;
  2455. }
  2456. public function doParse($yymajor, $yytokenvalue)
  2457. {
  2458. $yyerrorhit = 0; /* True if yymajor has invoked an error */
  2459. if ($this->yyidx === null || $this->yyidx < 0) {
  2460. $this->yyidx = 0;
  2461. $this->yyerrcnt = - 1;
  2462. $x = new TP_yyStackEntry;
  2463. $x->stateno = 0;
  2464. $x->major = 0;
  2465. $this->yystack = array();
  2466. $this->yystack[] = $x;
  2467. }
  2468. $yyendofinput = ($yymajor == 0);
  2469. if ($this->yyTraceFILE) {
  2470. fprintf($this->yyTraceFILE, "%sInput %s\n", $this->yyTracePrompt, $this->yyTokenName[ $yymajor ]);
  2471. }
  2472. do {
  2473. $yyact = $this->yy_find_shift_action($yymajor);
  2474. if ($yymajor < self::YYERRORSYMBOL && !$this->yy_is_expected_token($yymajor)) {
  2475. // force a syntax error
  2476. $yyact = self::YY_ERROR_ACTION;
  2477. }
  2478. if ($yyact < self::YYNSTATE) {
  2479. $this->yy_shift($yyact, $yymajor, $yytokenvalue);
  2480. $this->yyerrcnt --;
  2481. if ($yyendofinput && $this->yyidx >= 0) {
  2482. $yymajor = 0;
  2483. } else {
  2484. $yymajor = self::YYNOCODE;
  2485. }
  2486. } elseif ($yyact < self::YYNSTATE + self::YYNRULE) {
  2487. $this->yy_reduce($yyact - self::YYNSTATE);
  2488. } elseif ($yyact == self::YY_ERROR_ACTION) {
  2489. if ($this->yyTraceFILE) {
  2490. fprintf($this->yyTraceFILE, "%sSyntax Error!\n", $this->yyTracePrompt);
  2491. }
  2492. if (self::YYERRORSYMBOL) {
  2493. if ($this->yyerrcnt < 0) {
  2494. $this->yy_syntax_error($yymajor, $yytokenvalue);
  2495. }
  2496. $yymx = $this->yystack[ $this->yyidx ]->major;
  2497. if ($yymx == self::YYERRORSYMBOL || $yyerrorhit) {
  2498. if ($this->yyTraceFILE) {
  2499. fprintf($this->yyTraceFILE, "%sDiscard input token %s\n", $this->yyTracePrompt,
  2500. $this->yyTokenName[ $yymajor ]);
  2501. }
  2502. $this->yy_destructor($yymajor, $yytokenvalue);
  2503. $yymajor = self::YYNOCODE;
  2504. } else {
  2505. while ($this->yyidx >= 0 && $yymx != self::YYERRORSYMBOL &&
  2506. ($yyact = $this->yy_find_shift_action(self::YYERRORSYMBOL)) >= self::YYNSTATE) {
  2507. $this->yy_pop_parser_stack();
  2508. }
  2509. if ($this->yyidx < 0 || $yymajor == 0) {
  2510. $this->yy_destructor($yymajor, $yytokenvalue);
  2511. $this->yy_parse_failed();
  2512. $yymajor = self::YYNOCODE;
  2513. } elseif ($yymx != self::YYERRORSYMBOL) {
  2514. $u2 = 0;
  2515. $this->yy_shift($yyact, self::YYERRORSYMBOL, $u2);
  2516. }
  2517. }
  2518. $this->yyerrcnt = 3;
  2519. $yyerrorhit = 1;
  2520. } else {
  2521. if ($this->yyerrcnt <= 0) {
  2522. $this->yy_syntax_error($yymajor, $yytokenvalue);
  2523. }
  2524. $this->yyerrcnt = 3;
  2525. $this->yy_destructor($yymajor, $yytokenvalue);
  2526. if ($yyendofinput) {
  2527. $this->yy_parse_failed();
  2528. }
  2529. $yymajor = self::YYNOCODE;
  2530. }
  2531. } else {
  2532. $this->yy_accept();
  2533. $yymajor = self::YYNOCODE;
  2534. }
  2535. } while ($yymajor != self::YYNOCODE && $this->yyidx >= 0);
  2536. }
  2537. }