Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Changes In Branch tooltip-experiments Excluding Merge-Ins
This is equivalent to a diff from b406b414 to ac199e7a
2019-05-28
| ||
12:32 | Cherry-pick [ac199e7a8a]: Explicitly query the client mouse coordinates, to fix the positioning of tooltips for nodes in IE. ... (check-in: 3b5e74c4 user: florian tags: tooltip-copyhash) | |
12:16 | Explicitly query the client mouse coordinates, to fix the positioning of tooltips for nodes in IE. ... (Closed-Leaf check-in: ac199e7a user: florian tags: tooltip-experiments) | |
2019-05-27
| ||
06:58 | Ensure the close timer is started for tooltips belonging to nodes instead of rails, and prevent an out-of-bounds array access for double-clicks outside of rails. ... (check-in: d57c1a79 user: florian tags: tooltip-experiments) | |
2019-05-20
| ||
08:14 | Make the "click to show tooltip" action more "discoverable" with a changing mouse cursor, similar to the timeline nodes. This example uses the "pointer" cursor, but the "help" cursor may also be an option. ... (check-in: 8b8eaad8 user: florian tags: tooltip-experiments) | |
2019-05-18
| ||
21:08 | Merge the windows build fix from trunk into the tooltips branch. ... (Closed-Leaf check-in: b406b414 user: drh tags: tooltips) | |
21:05 | Back out check-in [344a3331d34d896] because it does not work with openssl-1.0.1. ... (check-in: f08b93da user: drh tags: trunk) | |
18:57 | Improvements to branch linkage from the tooltip. Branch linkage now works even from a file history graph. And the source check-in is always highlighted in the linked timeline. ... (check-in: a27ca27f user: drh tags: tooltips) | |
Changes to auto.def.
︙ | ︙ | |||
374 375 376 377 378 379 380 | # Silence OpenSSL deprecation warnings on Mac OS X 10.7. if {[string match *-darwin* [get-define host]]} { if {[cctest -cflags {-Wdeprecated-declarations}]} { define-append EXTRA_CFLAGS -Wdeprecated-declarations } } | < | 374 375 376 377 378 379 380 381 382 383 384 385 386 387 | # Silence OpenSSL deprecation warnings on Mac OS X 10.7. if {[string match *-darwin* [get-define host]]} { if {[cctest -cflags {-Wdeprecated-declarations}]} { define-append EXTRA_CFLAGS -Wdeprecated-declarations } } } else { user-error "OpenSSL not found. Consider --with-openssl=none to disable HTTPS support" } } else { if {[info exists ::zlib_lib]} { define-append LIBS $::zlib_lib } |
︙ | ︙ |
Changes to src/branch.c.
︙ | ︙ | |||
655 656 657 658 659 660 661 | blob_reset(&sql); /* Always specify TIMELINE_DISJOINT, or graph_finish() may fail because of too ** many descenders to (off-screen) parents. */ tmFlags = TIMELINE_DISJOINT | TIMELINE_NOSCROLL; if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH; if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR; if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR; | | | 655 656 657 658 659 660 661 662 663 664 665 | blob_reset(&sql); /* Always specify TIMELINE_DISJOINT, or graph_finish() may fail because of too ** many descenders to (off-screen) parents. */ tmFlags = TIMELINE_DISJOINT | TIMELINE_NOSCROLL; if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH; if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR; if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR; www_print_timeline(&q, tmFlags, 0, 0, 0, 0, brtimeline_extra); db_finalize(&q); style_footer(); } |
Changes to src/configure.c.
︙ | ︙ | |||
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 | { "footer", CONFIGSET_SKIN }, { "details", CONFIGSET_SKIN }, { "logo-mimetype", CONFIGSET_SKIN }, { "logo-image", CONFIGSET_SKIN }, { "background-mimetype", CONFIGSET_SKIN }, { "background-image", CONFIGSET_SKIN }, { "timeline-block-markup", CONFIGSET_SKIN }, { "timeline-max-comment", CONFIGSET_SKIN }, { "timeline-plaintext", CONFIGSET_SKIN }, { "adunit", CONFIGSET_SKIN }, { "adunit-omit-if-admin", CONFIGSET_SKIN }, { "adunit-omit-if-user", CONFIGSET_SKIN }, { "sitemap-docidx", CONFIGSET_SKIN }, { "sitemap-download", CONFIGSET_SKIN }, { "sitemap-license", CONFIGSET_SKIN }, { "sitemap-contact", CONFIGSET_SKIN }, | > > > > > | 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 | { "footer", CONFIGSET_SKIN }, { "details", CONFIGSET_SKIN }, { "logo-mimetype", CONFIGSET_SKIN }, { "logo-image", CONFIGSET_SKIN }, { "background-mimetype", CONFIGSET_SKIN }, { "background-image", CONFIGSET_SKIN }, { "timeline-block-markup", CONFIGSET_SKIN }, { "timeline-date-format", CONFIGSET_SKIN }, { "timeline-dwelltime", CONFIGSET_SKIN }, { "timeline-closetime", CONFIGSET_SKIN }, { "timeline-max-comment", CONFIGSET_SKIN }, { "timeline-plaintext", CONFIGSET_SKIN }, { "timeline-truncate-at-blank", CONFIGSET_SKIN }, { "timeline-utc", CONFIGSET_SKIN }, { "adunit", CONFIGSET_SKIN }, { "adunit-omit-if-admin", CONFIGSET_SKIN }, { "adunit-omit-if-user", CONFIGSET_SKIN }, { "sitemap-docidx", CONFIGSET_SKIN }, { "sitemap-download", CONFIGSET_SKIN }, { "sitemap-license", CONFIGSET_SKIN }, { "sitemap-contact", CONFIGSET_SKIN }, |
︙ | ︙ |
Changes to src/default_css.txt.
︙ | ︙ | |||
194 195 196 197 198 199 200 | .tl-line.dotted.v { width: 0px; border-left-width: 2px; border-left-style: dotted; background: rgba(255,255,255,0); } .tl-tooltip { | < < < < < < > | 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 | .tl-line.dotted.v { width: 0px; border-left-width: 2px; border-left-style: dotted; background: rgba(255,255,255,0); } .tl-tooltip { text-align: center; padding: 5px 1em; border: 1px solid black; border-radius: 6px; position: absolute; z-index: 100; box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.75); } span.tagDsp { font-weight: bold; } span.wikiError { font-weight: bold; |
︙ | ︙ |
Changes to src/descendants.c.
︙ | ︙ | |||
538 539 540 541 542 543 544 | blob_reset(&sql); /* Always specify TIMELINE_DISJOINT, or graph_finish() may fail because of too ** many descenders to (off-screen) parents. */ tmFlags = TIMELINE_LEAFONLY | TIMELINE_DISJOINT | TIMELINE_NOSCROLL; if( fNg==0 ) tmFlags |= TIMELINE_GRAPH; if( fBrBg ) tmFlags |= TIMELINE_BRCOLOR; if( fUBg ) tmFlags |= TIMELINE_UCOLOR; | | | 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 | blob_reset(&sql); /* Always specify TIMELINE_DISJOINT, or graph_finish() may fail because of too ** many descenders to (off-screen) parents. */ tmFlags = TIMELINE_LEAFONLY | TIMELINE_DISJOINT | TIMELINE_NOSCROLL; if( fNg==0 ) tmFlags |= TIMELINE_GRAPH; if( fBrBg ) tmFlags |= TIMELINE_BRCOLOR; if( fUBg ) tmFlags |= TIMELINE_UCOLOR; www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0); db_finalize(&q); @ <br /> style_footer(); } #if INTERFACE /* Flag parameters to compute_uses_file() */ |
︙ | ︙ |
Changes to src/finfo.c.
︙ | ︙ | |||
643 644 645 646 647 648 649 | @ </span> } @ </td></tr> } db_finalize(&q); db_finalize(&qparent); if( pGraph ){ | | | 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | @ </span> } @ </td></tr> } db_finalize(&q); db_finalize(&qparent); if( pGraph ){ graph_finish(pGraph, 0, TIMELINE_DISJOINT); if( pGraph->nErr ){ graph_free(pGraph); pGraph = 0; }else{ @ <tr class="timelineBottom" id="btm-%d(iTableId)">\ @ <td></td><td></td><td></td></tr> } |
︙ | ︙ |
Changes to src/graph.c.
︙ | ︙ | |||
71 72 73 74 75 76 77 78 79 80 81 82 83 84 | GraphRow *pChild; /* Child immediately above this node */ u8 isDup; /* True if this is duplicate of a prior entry */ u8 isLeaf; /* True if this is a leaf node */ u8 isStepParent; /* pChild is actually a step-child */ u8 hasNormalOutMerge; /* Is parent of at laest 1 non-cherrypick merge */ u8 timeWarp; /* Child is earlier in time */ u8 bDescender; /* True if riser from bottom of graph to here. */ i8 iRail; /* Which rail this check-in appears on. 0-based.*/ i8 mergeOut; /* Merge out to this rail. -1 if no merge-out */ u8 mergeIn[GR_MAX_RAIL]; /* Merge in from non-zero rails */ int aiRiser[GR_MAX_RAIL]; /* Risers from this node to a higher row. */ int mergeUpto; /* Draw the mergeOut rail up to this level */ int cherrypickUpto; /* Continue the mergeOut rail up to here */ u64 mergeDown; /* Draw merge lines up from bottom of graph */ | > | 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 | GraphRow *pChild; /* Child immediately above this node */ u8 isDup; /* True if this is duplicate of a prior entry */ u8 isLeaf; /* True if this is a leaf node */ u8 isStepParent; /* pChild is actually a step-child */ u8 hasNormalOutMerge; /* Is parent of at laest 1 non-cherrypick merge */ u8 timeWarp; /* Child is earlier in time */ u8 bDescender; /* True if riser from bottom of graph to here. */ u8 selfUp; /* Space above this node but belonging */ i8 iRail; /* Which rail this check-in appears on. 0-based.*/ i8 mergeOut; /* Merge out to this rail. -1 if no merge-out */ u8 mergeIn[GR_MAX_RAIL]; /* Merge in from non-zero rails */ int aiRiser[GR_MAX_RAIL]; /* Risers from this node to a higher row. */ int mergeUpto; /* Draw the mergeOut rail up to this level */ int cherrypickUpto; /* Continue the mergeOut rail up to here */ u64 mergeDown; /* Draw merge lines up from bottom of graph */ |
︙ | ︙ | |||
94 95 96 97 98 99 100 101 102 103 104 105 106 107 | GraphRow *pFirst; /* First row in the list. Top row of graph. */ GraphRow *pLast; /* Last row in the list. Bottom row of graph. */ int nBranch; /* Number of distinct branches */ char **azBranch; /* Names of the branches */ int nRow; /* Number of rows */ int nHash; /* Number of slots in apHash[] */ GraphRow **apHash; /* Hash table of GraphRow objects. Key: rid */ }; #endif /* The N-th bit */ #define BIT(N) (((u64)1)<<(N)) | > | 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 | GraphRow *pFirst; /* First row in the list. Top row of graph. */ GraphRow *pLast; /* Last row in the list. Bottom row of graph. */ int nBranch; /* Number of distinct branches */ char **azBranch; /* Names of the branches */ int nRow; /* Number of rows */ int nHash; /* Number of slots in apHash[] */ GraphRow **apHash; /* Hash table of GraphRow objects. Key: rid */ u8 aiRailMap[GR_MAX_RAIL]; /* Mapping of rails to actually columns */ }; #endif /* The N-th bit */ #define BIT(N) (((u64)1)<<(N)) |
︙ | ︙ | |||
316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 | assert( pPrior!=0 ); } } /* Mask of additional rows for the riser to infinity */ if( !pPrior->isLeaf && (tmFlags & TIMELINE_DISJOINT)==0 ){ int n = RISER_MARGIN; GraphRow *p; for(p=pPrior; p && (n--)>0; p=p->pPrev){ p->railInUse |= mask; } } } /* ** Create a merge-arrow riser going from pParent up to pChild. | > > | 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 | assert( pPrior!=0 ); } } /* Mask of additional rows for the riser to infinity */ if( !pPrior->isLeaf && (tmFlags & TIMELINE_DISJOINT)==0 ){ int n = RISER_MARGIN; GraphRow *p; pPrior->selfUp = 0; for(p=pPrior; p && (n--)>0; p=p->pPrev){ pPrior->selfUp++; p->railInUse |= mask; } } } /* ** Create a merge-arrow riser going from pParent up to pChild. |
︙ | ︙ | |||
342 343 344 345 346 347 348 349 350 351 352 | if( pParent->mergeOut<0 ){ u = pParent->aiRiser[pParent->iRail]; if( u>0 && u<pChild->idx ){ /* The thick arrow up to the next primary child of pDesc goes ** further up than the thin merge arrow riser, so draw them both ** on the same rail. */ pParent->mergeOut = pParent->iRail; }else{ /* The thin merge arrow riser is taller than the thick primary ** child riser, so use separate rails. */ int iTarget = pParent->iRail; | > > < | | 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 | if( pParent->mergeOut<0 ){ u = pParent->aiRiser[pParent->iRail]; if( u>0 && u<pChild->idx ){ /* The thick arrow up to the next primary child of pDesc goes ** further up than the thin merge arrow riser, so draw them both ** on the same rail. */ pParent->mergeOut = pParent->iRail; }else if( pParent->idx - pChild->idx < pParent->selfUp ){ pParent->mergeOut = pParent->iRail; }else{ /* The thin merge arrow riser is taller than the thick primary ** child riser, so use separate rails. */ int iTarget = pParent->iRail; pParent->mergeOut = findFreeRail(p, pChild->idx, pParent->idx-1, iTarget); mask = BIT(pParent->mergeOut); for(pLoop=pChild->pNext; pLoop && pLoop->rid!=pParent->rid; pLoop=pLoop->pNext){ pLoop->railInUse |= mask; } } } |
︙ | ︙ | |||
415 416 417 418 419 420 421 | ** The tmFlags parameter is zero or more of the TIMELINE_* constants. ** Only the following are honored: ** ** TIMELINE_DISJOINT: Omit descenders ** TIMELINE_FILLGAPS: Use step-children ** TIMELINE_XMERGE: Omit off-graph merge lines */ | | > | 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 | ** The tmFlags parameter is zero or more of the TIMELINE_* constants. ** Only the following are honored: ** ** TIMELINE_DISJOINT: Omit descenders ** TIMELINE_FILLGAPS: Use step-children ** TIMELINE_XMERGE: Omit off-graph merge lines */ void graph_finish(GraphContext *p, const char *zLeftBranch, u32 tmFlags){ GraphRow *pRow, *pDesc, *pDup, *pLoop, *pParent; int i, j; u64 mask; int hasDup = 0; /* True if one or more isDup entries */ const char *zTrunk; u8 *aMap; /* Copy of p->aiRailMap */ int omitDescenders = (tmFlags & TIMELINE_DISJOINT)!=0; /* If mergeRiserFrom[X]==Y that means rail X holds a merge riser ** coming up from the bottom of the graph from off-screen check-in Y ** where Y is the RID. There is no riser on rail X if mergeRiserFrom[X]==0. */ int mergeRiserFrom[GR_MAX_RAIL]; |
︙ | ︙ | |||
514 515 516 517 518 519 520 | if( pRow->isDup ) continue; if( pRow->nParent<=0 ) continue; /* Root node */ pParent = hashFind(p, pRow->aParent[0]); if( pParent==0 ) continue; /* Parent off-screen */ if( pParent->zBranch!=pRow->zBranch ) continue; /* Different branch */ if( pParent->idx <= pRow->idx ){ pParent->timeWarp = 1; | | > | | | | 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 | if( pRow->isDup ) continue; if( pRow->nParent<=0 ) continue; /* Root node */ pParent = hashFind(p, pRow->aParent[0]); if( pParent==0 ) continue; /* Parent off-screen */ if( pParent->zBranch!=pRow->zBranch ) continue; /* Different branch */ if( pParent->idx <= pRow->idx ){ pParent->timeWarp = 1; }else if( pRow->idxTop < pParent->idxTop ){ pParent->pChild = pRow; pParent->idxTop = pRow->idxTop; } } if( tmFlags & TIMELINE_FILLGAPS ){ /* If a node has no pChild and there is a node higher up in the graph ** that is in the same branch and has no in-graph parent, then ** make the lower node a step-child of the upper node. This will ** be represented on the graph by a thick dotted line without an arrowhead. */ for(pRow=p->pFirst; pRow; pRow=pRow->pNext){ if( pRow->pChild ) continue; for(pLoop=pRow->pPrev; pLoop; pLoop=pLoop->pPrev){ if( pLoop->nParent>0 && pLoop->zBranch==pRow->zBranch |
︙ | ︙ | |||
711 712 713 714 715 716 717 718 719 | if( mxRail>=GR_MAX_RAIL ) return; } /* ** Find the maximum rail number. */ find_max_rail(p); p->nErr = 0; } | > > > > > > > > > > > > > > > > > > > > > > | 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 | if( mxRail>=GR_MAX_RAIL ) return; } /* ** Find the maximum rail number. */ find_max_rail(p); /* ** Compute the rail mapping. */ aMap = p->aiRailMap; for(i=0; i<=p->mxRail; i++) aMap[i] = i; if( zLeftBranch ){ char *zLeft = persistBranchName(p, zLeftBranch); j = 0; for(pRow=p->pFirst; pRow; pRow=pRow->pNext){ if( pRow->zBranch==zLeft && aMap[pRow->iRail]>=j ){ for(i=0; i<=p->mxRail; i++){ if( aMap[i]>=j && aMap[i]<=pRow->iRail ) aMap[i]++; } aMap[pRow->iRail] = j++; } } cgi_printf("<!-- aiRailMap ="); for(i=0; i<=p->mxRail; i++) cgi_printf(" %d", aMap[i]); cgi_printf(" -->\n"); } p->nErr = 0; } |
Changes to src/graph.js.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | /* This module contains javascript needed to render timeline graphs in Fossil. ** ** Prior to sourcing this script, there should be a separate ** <script type='application/json' id='timeline-data-NN'> for each graph, ** each containing JSON like this: ** ** { "iTableId": INTEGER, // Table sequence number (NN) ** "circleNodes": BOOLEAN, // True for circle nodes. False for squares ** "showArrowheads": BOOLEAN, // True for arrowheads. False to omit ** "iRailPitch": INTEGER, // Spacing between vertical lines (px) ** "colorGraph": BOOLEAN, // True to put color on graph lines ** "nomo": BOOLEAN, // True to join merge lines with rails ** "iTopRow": INTEGER, // Index of top-most row in the graph ** "omitDescenders": BOOLEAN, // Omit ancestor lines off bottom of screen ** "fileDiff": BOOLEAN, // True for file diff. False for check-in ** "scrollToSelect": BOOLEAN, // Scroll to selection on first render ** "nrail": INTEGER, // Number of vertical "rails" ** "baseUrl": TEXT, // Top-level URL ** "rowinfo": ROWINFO-ARRAY } ** ** The rowinfo field is an array of structures, one per entry in the timeline, ** where each structure has the following fields: ** ** id: The id of the <div> element for the row. This is an integer. ** to get an actual id, prepend "m" to the integer. The top node | > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | /* This module contains javascript needed to render timeline graphs in Fossil. ** ** There can be multiple graphs on a single webpage, but this script is only ** loaded once. ** ** Prior to sourcing this script, there should be a separate ** <script type='application/json' id='timeline-data-NN'> for each graph, ** each containing JSON like this: ** ** { "iTableId": INTEGER, // Table sequence number (NN) ** "circleNodes": BOOLEAN, // True for circle nodes. False for squares ** "showArrowheads": BOOLEAN, // True for arrowheads. False to omit ** "iRailPitch": INTEGER, // Spacing between vertical lines (px) ** "colorGraph": BOOLEAN, // True to put color on graph lines ** "nomo": BOOLEAN, // True to join merge lines with rails ** "iTopRow": INTEGER, // Index of top-most row in the graph ** "omitDescenders": BOOLEAN, // Omit ancestor lines off bottom of screen ** "fileDiff": BOOLEAN, // True for file diff. False for check-in ** "scrollToSelect": BOOLEAN, // Scroll to selection on first render ** "nrail": INTEGER, // Number of vertical "rails" ** "baseUrl": TEXT, // Top-level URL ** "dwellTimeout": INTEGER, // Tooltip show delay in milliseconds ** "closeTimeout": INTEGER, // Tooltip close delay in milliseconds ** "rowinfo": ROWINFO-ARRAY } ** ** The rowinfo field is an array of structures, one per entry in the timeline, ** where each structure has the following fields: ** ** id: The id of the <div> element for the row. This is an integer. ** to get an actual id, prepend "m" to the integer. The top node |
︙ | ︙ | |||
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | ** and a thin merge-arrow descender is drawn to the bottom of ** the screen. This array is omitted if there are no inbound ** merges. ** ci: "cherrypick-in". Like "mi" except for cherrypick merges. ** omitted if there are no cherrypick merges. ** h: The artifact hash of the object being graphed */ var amendCssOnce = 1; // Only change the CSS one time function amendCss(circleNodes,showArrowheads){ if( !amendCssOnce ) return; var css = ""; if( circleNodes ){ css += ".tl-node, .tl-node:after { border-radius: 50%; }"; } if( !showArrowheads ){ css += ".tl-arrow.u { display: none; }"; } if( css!=="" ){ var style = document.createElement("style"); style.textContent = css; document.querySelector("head").appendChild(style); } amendCssOnce = 0; } var tooltipObj = document.createElement("span"); tooltipObj.className = "tl-tooltip"; | > > > > > > > | > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 | ** and a thin merge-arrow descender is drawn to the bottom of ** the screen. This array is omitted if there are no inbound ** merges. ** ci: "cherrypick-in". Like "mi" except for cherrypick merges. ** omitted if there are no cherrypick merges. ** h: The artifact hash of the object being graphed */ /* The amendCss() function does a one-time change to the CSS to account ** for the "circleNodes" and "showArrowheads" settings. Do this change ** only once, even if there are multiple graphs being rendered. */ var amendCssOnce = 1; // Only change the CSS one time function amendCss(circleNodes,showArrowheads){ if( !amendCssOnce ) return; var css = ""; if( circleNodes ){ css += ".tl-node, .tl-node:after { border-radius: 50%; }"; } if( !showArrowheads ){ css += ".tl-arrow.u { display: none; }"; } if( css!=="" ){ var style = document.createElement("style"); style.textContent = css; document.querySelector("head").appendChild(style); } amendCssOnce = 0; } /* The <span> object that holds the tooltip */ var tooltipObj = document.createElement("span"); tooltipObj.className = "tl-tooltip"; tooltipObj.style.display = "none"; document.getElementsByClassName("content")[0].appendChild(tooltipObj); tooltipObj.onmouseenter = function(){stopCloseTimer();} tooltipObj.onmouseleave = function(){ if (tooltipInfo.ixActive != -1) resumeCloseTimer(); }; /* State information for the tooltip popup and its timers */ window.tooltipInfo = { dwellTimeout: 250, /* The tooltip dwell timeout. */ closeTimeout: 3000, /* The tooltip close timeout. */ idTimer: 0, /* The tooltip dwell timer id. */ idTimerClose: 0, /* The tooltip close timer id. */ ixHover: -1, /* The id of the element with the mouse. */ ixActive: -1, /* The id of the element with the tooltip. */ nodeHover: null, /* Graph node under mouse when ixHover==-2 */ posX: 0, posY: 0 /* The last mouse position. */ }; /* Functions used to control the tooltip popup and its timer */ function hideGraphTooltip(){ stopCloseTimer(); tooltipObj.style.display = "none"; tooltipInfo.ixActive = -1; } document.body.onunload = hideGraphTooltip function stopDwellTimer(){ if (tooltipInfo.idTimer != 0) { clearTimeout(tooltipInfo.idTimer); tooltipInfo.idTimer = 0; } } function resumeCloseTimer(){ /* This timer must be stopped explicitly to reset the elapsed timeout. */ if(tooltipInfo.idTimerClose == 0 && tooltipInfo.closeTimeout>0) { tooltipInfo.idTimerClose = setTimeout(function(){ tooltipInfo.idTimerClose = 0; hideGraphTooltip(); },tooltipInfo.closeTimeout); } } function stopCloseTimer(){ if (tooltipInfo.idTimerClose != 0) { clearTimeout(tooltipInfo.idTimerClose); tooltipInfo.idTimerClose = 0; } } /* Construct that graph corresponding to the timeline-data-N object that ** is passed in by the tx parameter */ function TimelineGraph(tx){ var topObj = document.getElementById("timelineTable"+tx.iTableId); amendCss(tx.circleNodes, tx.showArrowheads); tooltipInfo.dwellTimeout = tx.dwellTimeout tooltipInfo.closeTimeout = tx.closeTimeout topObj.onclick = clickOnGraph topObj.ondblclick = dblclickOnGraph topObj.onmousemove = function(e) { var ix = findTxIndex(e); topObj.style.cursor = (ix<0) ? "" : "pointer" /* Keep the already visible tooltip at a constant position, as long as the ** mouse is over the same element. */ if(tooltipObj.style.display != "none"){ if(ix == tooltipInfo.ixHover) return; } /* The tooltip is either not visible, or the mouse is over a different ** element, so clear the dwell timer, and record the new element id and ** mouse position. */ stopDwellTimer(); if(ix >= 0){ tooltipInfo.ixHover = ix; tooltipInfo.posX = e.clientX; tooltipInfo.posY = e.clientY; stopCloseTimer(); if(tooltipInfo.dwellTimeout>0){ tooltipInfo.idTimer = setTimeout(function() { tooltipInfo.idTimer = 0; stopCloseTimer(); showGraphTooltip(); },tooltipInfo.dwellTimeout); } }else{ /* The mouse is not over an element with a tooltip */ tooltipInfo.ixHover = -1; resumeCloseTimer(); } }; topObj.onmouseleave = function(e) { /* Hide the tooltip if the mouse is outside the "timelineTableN" element, ** and outside the tooltip. */ if(e.relatedTarget && e.relatedTarget != tooltipObj){ tooltipInfo.ixHover = -1; hideGraphTooltip(); stopDwellTimer(); stopCloseTimer(); } }; function nodeHover(e){ /* Invoked by mousemove events over a graph node */ e.stopPropagation() if(tooltipInfo.ixHover==-2) return tooltipInfo.ixHover = -2 tooltipInfo.posX = e.clientX tooltipInfo.posY = e.clientY tooltipInfo.nodeHover = this stopCloseTimer(); if(tooltipInfo.dwellTimeout>0){ tooltipInfo.idTimer = setTimeout(function() { tooltipInfo.idTimer = 0; stopCloseTimer(); showGraphTooltip(); },tooltipInfo.dwellTimeout); } } var canvasDiv; var railPitch; var mergeOffset; var node, arrow, arrowSmall, line, mArrow, mLine, wArrow, wLine; function initGraph(){ var parent = topObj.rows[0].cells[1]; |
︙ | ︙ | |||
267 268 269 270 271 272 273 | if( p.u>0 ) drawUpArrow(p,tx.rowinfo[p.u-tx.iTopRow],p.fg,p.id); if( p.sb>0 ) drawDotted(p,tx.rowinfo[p.sb-tx.iTopRow],p.fg,p.id); var cls = node.cls; if( p.hasOwnProperty('mi') && p.mi.length ) cls += " merge"; if( p.f&1 ) cls += " leaf"; var n = drawBox(cls,p.bg,p.x,p.y); n.id = "tln"+p.id; | < > | 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 | if( p.u>0 ) drawUpArrow(p,tx.rowinfo[p.u-tx.iTopRow],p.fg,p.id); if( p.sb>0 ) drawDotted(p,tx.rowinfo[p.sb-tx.iTopRow],p.fg,p.id); var cls = node.cls; if( p.hasOwnProperty('mi') && p.mi.length ) cls += " merge"; if( p.f&1 ) cls += " leaf"; var n = drawBox(cls,p.bg,p.x,p.y); n.id = "tln"+p.id; n.onclick = clickOnNode; n.ondblclick = dblclickOnNode; n.onmousemove = nodeHover; n.style.zIndex = 10; if( !tx.omitDescenders ){ if( p.u==0 ){ if( p.hasOwnProperty('mo') && p.r==p.mo ){ var ix = p.hasOwnProperty('cu') ? p.cu : p.mu; var top = tx.rowinfo[ix-tx.iTopRow] drawUpArrow(p,{x: p.x, y: top.y-node.h}, p.fg, p.id); |
︙ | ︙ | |||
410 411 412 413 414 415 416 | for( var i=0; i<tx.nrail; i++) mergeBtm[i] = btm; for( var i=tx.rowinfo.length-1; i>=0; i-- ){ drawNode(tx.rowinfo[i], btm); } } var selRow; function clickOnNode(e){ | | | 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 | for( var i=0; i<tx.nrail; i++) mergeBtm[i] = btm; for( var i=tx.rowinfo.length-1; i>=0; i-- ){ drawNode(tx.rowinfo[i], btm); } } var selRow; function clickOnNode(e){ hideGraphTooltip() var p = tx.rowinfo[parseInt(this.id.match(/\d+$/)[0], 10)-tx.iTopRow]; if( !selRow ){ selRow = p; this.className += " sel"; canvasDiv.className += " sel"; }else if( selRow==p ){ selRow = null; |
︙ | ︙ | |||
438 439 440 441 442 443 444 | window.location.href = tx.baseUrl+"/info/"+p.h e.stopPropagation() } function findTxIndex(e){ /* Look at all the graph elements. If any graph elements that is near ** the click-point "e" and has a "data-ix" attribute, then return ** the value of that attribute. Otherwise return -1 */ | | | | 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 | window.location.href = tx.baseUrl+"/info/"+p.h e.stopPropagation() } function findTxIndex(e){ /* Look at all the graph elements. If any graph elements that is near ** the click-point "e" and has a "data-ix" attribute, then return ** the value of that attribute. Otherwise return -1 */ var x = e.clientX + window.pageXOffset - absoluteX(canvasDiv); var y = e.clientY + window.pageYOffset - absoluteY(canvasDiv); var aNode = canvasDiv.childNodes var nNode = aNode.length; var i; for(i=0;i<nNode;i++){ var n = aNode[i] if( !n.hasAttribute("data-ix") ) continue; if( x<n.offsetLeft-5 ) continue; |
︙ | ︙ | |||
463 464 465 466 467 468 469 | var br = tx.rowinfo[ix].br var dest = tx.baseUrl + "/timeline?r=" + encodeURIComponent(br) dest += tx.fileDiff ? "&m&cf=" : "&m&c=" dest += encodeURIComponent(tx.rowinfo[ix].h) return dest } function clickOnGraph(e){ | > > > > > > > | > > > > | | | > > > > > > > > > > > > > > > > > > > | | > > | > > > > > | < | > | 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 | var br = tx.rowinfo[ix].br var dest = tx.baseUrl + "/timeline?r=" + encodeURIComponent(br) dest += tx.fileDiff ? "&m&cf=" : "&m&c=" dest += encodeURIComponent(tx.rowinfo[ix].h) return dest } function clickOnGraph(e){ tooltipInfo.ixHover = findTxIndex(e); tooltipInfo.posX = e.clientX; tooltipInfo.posY = e.clientY; showGraphTooltip(); } function showGraphTooltip(){ var html = null var ix = -1 if( tooltipInfo.ixHover==-2 ){ ix = parseInt(tooltipInfo.nodeHover.id.match(/\d+$/)[0],10)-tx.iTopRow var h = tx.rowinfo[ix].h var dest = tx.baseUrl + "/info/" + h if( tx.fileDiff ){ html = "artifact <a href=\""+dest+"\">"+h+"</a>" }else{ html = "check-in <a href=\""+dest+"\">"+h+"</a>" } tooltipInfo.ixActive = -2; }else if( tooltipInfo.ixHover>=0 ){ ix = tooltipInfo.ixHover var br = tx.rowinfo[ix].br var dest = branchHyperlink(ix) var hbr = br.replace(/&/g, "&") .replace(/</g, "<") .replace(/>/g, ">") .replace(/"/g, """) .replace(/'/g, "'"); html = "branch <a href=\""+dest+"\">"+hbr+"</a>" tooltipInfo.ixActive = ix; } if( html ){ /* Setup while hidden, to ensure proper dimensions. */ var s = getComputedStyle(document.body) if( tx.rowinfo[ix].bg.length ){ tooltipObj.style.backgroundColor = tx.rowinfo[ix].bg }else{ tooltipObj.style.backgroundColor = s.getPropertyValue('background-color') } tooltipObj.style.borderColor = tooltipObj.style.color = s.getPropertyValue('color') tooltipObj.style.visibility = "hidden" tooltipObj.innerHTML = html tooltipObj.style.display = "inline" tooltipObj.style.position = "absolute" var x = tooltipInfo.posX + 4 + window.pageXOffset - absoluteX(tooltipObj.offsetParent) tooltipObj.style.left = x+"px" var y = tooltipInfo.posY + window.pageYOffset - tooltipObj.clientHeight - 4 - absoluteY(tooltipObj.offsetParent) tooltipObj.style.top = y+"px" tooltipObj.style.visibility = "visible" }else{ hideGraphTooltip() } } function dblclickOnGraph(e){ var ix = findTxIndex(e); hideGraphTooltip() if( ix>=0 ){ var dest = branchHyperlink(ix) window.location.href = dest } } function changeDisplay(selector,value){ var x = document.getElementsByClassName(selector); var n = x.length; for(var i=0; i<n; i++) {x[i].style.display = value;} } function changeDisplayById(id,value){ |
︙ | ︙ |
Changes to src/http_ssl.c.
︙ | ︙ | |||
385 386 387 388 389 390 391 | } /* Set the Global.zIpAddr variable to the server we are talking to. ** This is used to populate the ipaddr column of the rcvfrom table, ** if any files are received from the server. */ { | | > > > | 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 | } /* Set the Global.zIpAddr variable to the server we are talking to. ** This is used to populate the ipaddr column of the rcvfrom table, ** if any files are received from the server. */ { /* As soon as libressl implements BIO_ADDR_hostname_string/BIO_get_conn_address. * check here for the correct LIBRESSL_VERSION_NUMBER too. For now: disable */ #if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x10100000L \ && !defined(LIBRESSL_VERSION_NUMBER) char *ip = BIO_ADDR_hostname_string(BIO_get_conn_address(iBio),1); g.zIpAddr = mprintf("%s", ip); OPENSSL_free(ip); #else /* IPv4 only code */ const unsigned char *ip; ip = (const unsigned char*)BIO_ptr_ctrl(iBio,BIO_C_GET_CONNECT,2); |
︙ | ︙ |
Changes to src/info.c.
︙ | ︙ | |||
284 285 286 287 288 289 290 | db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_GRAPH |TIMELINE_FILLGAPS |TIMELINE_NOSCROLL |TIMELINE_XMERGE |TIMELINE_CHPICK, | | | 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 | db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_GRAPH |TIMELINE_FILLGAPS |TIMELINE_NOSCROLL |TIMELINE_XMERGE |TIMELINE_CHPICK, 0, 0, 0, rid, 0); db_finalize(&q); } /* ** Show a graph all wiki, tickets, and check-ins that refer to object zUuid. ** ** If zLabel is not NULL and the graph is not empty, then output zLabel as |
︙ | ︙ | |||
315 316 317 318 319 320 321 | if( !db_exists("SELECT 1 FROM ok") ) return; if( zLabel ) cgi_printf("%s", zLabel); blob_zero(&sql); blob_append(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC"); db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL, | | | 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 | if( !db_exists("SELECT 1 FROM ok") ) return; if( zLabel ) cgi_printf("%s", zLabel); blob_zero(&sql); blob_append(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC"); db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL, 0, 0, 0, 0, 0); db_finalize(&q); } /* ** WEBPAGE: test-backlinks ** ** Show a timeline of all check-ins and other events that have entries |
︙ | ︙ | |||
348 349 350 351 352 353 354 | " WHERE blob.uuid BETWEEN backlink.target AND (backlink.target||'x')" ); blob_zero(&sql); blob_append(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC"); db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL, | | | 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 | " WHERE blob.uuid BETWEEN backlink.target AND (backlink.target||'x')" ); blob_zero(&sql); blob_append(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC"); db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL, 0, 0, 0, 0, 0); db_finalize(&q); style_footer(); } /* ** Append the difference between artifacts to the output |
︙ | ︙ | |||
617 618 619 620 621 622 623 | " ORDER BY tagname /*sort*/", rid, rid, rid ); blob_zero(&sql); blob_append(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC"); db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL, | | | 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 | " ORDER BY tagname /*sort*/", rid, rid, rid ); blob_zero(&sql); blob_append(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN ok ORDER BY mtime DESC"); db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, TIMELINE_DISJOINT|TIMELINE_GRAPH|TIMELINE_NOSCROLL, 0, 0, 0, rid, 0); db_finalize(&q); style_footer(); } /* ** WEBPAGE: vinfo ** WEBPAGE: ci |
︙ | ︙ |
Changes to src/moderate.c.
︙ | ︙ | |||
182 183 184 185 186 187 188 | if( moderation_table_exists() ){ blob_init(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN (SELECT objid FROM modreq)" " ORDER BY event.mtime DESC" ); db_prepare(&q, "%s", blob_sql_text(&sql)); | | | 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 | if( moderation_table_exists() ){ blob_init(&sql, timeline_query_for_www(), -1); blob_append_sql(&sql, " AND event.objid IN (SELECT objid FROM modreq)" " ORDER BY event.mtime DESC" ); db_prepare(&q, "%s", blob_sql_text(&sql)); www_print_timeline(&q, 0, 0, 0, 0, 0, 0); db_finalize(&q); } style_footer(); } /* ** Disapproves any entries in the modreq table which belong to any |
︙ | ︙ |
Changes to src/setup.c.
︙ | ︙ | |||
747 748 749 750 751 752 753 754 755 756 757 758 759 760 | @ <hr /> entry_attribute("Max timeline comment length", 6, "timeline-max-comment", "tmc", "0", 0); @ <p>The maximum length of a comment to be displayed in a timeline. @ "0" there is no length limit. @ (Property: "timeline-max-comment")</p> @ <hr /> @ <p><input type="submit" name="submit" value="Apply Changes" /></p> @ </div></form> db_end_transaction(0); style_footer(); } | > > > > > > > > > > > > > > > > | 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 | @ <hr /> entry_attribute("Max timeline comment length", 6, "timeline-max-comment", "tmc", "0", 0); @ <p>The maximum length of a comment to be displayed in a timeline. @ "0" there is no length limit. @ (Property: "timeline-max-comment")</p> @ <hr /> entry_attribute("Tooltip dwell time (milliseconds)", 6, "timeline-dwelltime", "tdt", "100", 0); @ <br> entry_attribute("Tooltip close time (milliseconds)", 6, "timeline-closetime", "tct", "250", 0); @ <p>The <strong>dwell time</strong> defines how long the mouse pointer @ should be stationary above an object of the graph before a tooltip @ appears.<br> @ The <strong>close time</strong> defines how long the mouse pointer @ can be away from an object before a tooltip is closed.</p> @ <p>Set <strong>dwell time</strong> to "0" to disable tooltips.<br> @ Set <strong>close time</strong> to "0" to keep tooltips visible until @ the mouse is clicked elsewhere.<p> @ <p>(Properties: "timeline-dwelltime", "timeline-closetime")</p> @ <hr /> @ <p><input type="submit" name="submit" value="Apply Changes" /></p> @ </div></form> db_end_transaction(0); style_footer(); } |
︙ | ︙ |
Changes to src/sqlite3.c.
︙ | ︙ | |||
1165 1166 1167 1168 1169 1170 1171 | ** ** See also: [sqlite3_libversion()], ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ #define SQLITE_VERSION "3.29.0" #define SQLITE_VERSION_NUMBER 3029000 | | | 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 | ** ** See also: [sqlite3_libversion()], ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ #define SQLITE_VERSION "3.29.0" #define SQLITE_VERSION_NUMBER 3029000 #define SQLITE_SOURCE_ID "2019-05-23 16:38:12 d2fe370cafa9b11f6c3eb4e1c3be48d9d2610b9d2f9d9ebf9e50267f9079dfc0" /* ** CAPI3REF: Run-Time Library Version Numbers ** KEYWORDS: sqlite3_version sqlite3_sourceid ** ** These interfaces provide the same information as the [SQLITE_VERSION], ** [SQLITE_VERSION_NUMBER], and [SQLITE_SOURCE_ID] C preprocessor macros |
︙ | ︙ | |||
3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 | ** <dd>The SQLITE_DBCONFIG_DEFENSIVE option activates or deactivates the ** "defensive" flag for a database connection. When the defensive ** flag is enabled, language features that allow ordinary SQL to ** deliberately corrupt the database file are disabled. The disabled ** features include but are not limited to the following: ** <ul> ** <li> The [PRAGMA writable_schema=ON] statement. ** <li> Writes to the [sqlite_dbpage] virtual table. ** <li> Direct writes to [shadow tables]. ** </ul> ** </dd> ** ** [[SQLITE_DBCONFIG_WRITABLE_SCHEMA]] <dt>SQLITE_DBCONFIG_WRITABLE_SCHEMA</dt> ** <dd>The SQLITE_DBCONFIG_WRITABLE_SCHEMA option activates or deactivates the | > | 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 | ** <dd>The SQLITE_DBCONFIG_DEFENSIVE option activates or deactivates the ** "defensive" flag for a database connection. When the defensive ** flag is enabled, language features that allow ordinary SQL to ** deliberately corrupt the database file are disabled. The disabled ** features include but are not limited to the following: ** <ul> ** <li> The [PRAGMA writable_schema=ON] statement. ** <li> The [PRAGMA journal_mode=OFF] statement. ** <li> Writes to the [sqlite_dbpage] virtual table. ** <li> Direct writes to [shadow tables]. ** </ul> ** </dd> ** ** [[SQLITE_DBCONFIG_WRITABLE_SCHEMA]] <dt>SQLITE_DBCONFIG_WRITABLE_SCHEMA</dt> ** <dd>The SQLITE_DBCONFIG_WRITABLE_SCHEMA option activates or deactivates the |
︙ | ︙ | |||
13954 13955 13956 13957 13958 13959 13960 | ** ** For best performance, an attempt is made to guess at the byte-order ** using C-preprocessor macros. If that is unsuccessful, or if ** -DSQLITE_BYTEORDER=0 is set, then byte-order is determined ** at run-time. */ #ifndef SQLITE_BYTEORDER | | | | | | > | 13955 13956 13957 13958 13959 13960 13961 13962 13963 13964 13965 13966 13967 13968 13969 13970 13971 13972 13973 13974 13975 | ** ** For best performance, an attempt is made to guess at the byte-order ** using C-preprocessor macros. If that is unsuccessful, or if ** -DSQLITE_BYTEORDER=0 is set, then byte-order is determined ** at run-time. */ #ifndef SQLITE_BYTEORDER # if defined(i386) || defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64) || defined(__x86_64__) || defined(_M_X64) || \ defined(_M_AMD64) || defined(_M_ARM) || defined(__x86) || \ defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) # define SQLITE_BYTEORDER 1234 # elif defined(sparc) || defined(__ppc__) || \ defined(__ARMEB__) || defined(__AARCH64EB__) # define SQLITE_BYTEORDER 4321 # else # define SQLITE_BYTEORDER 0 # endif #endif #if SQLITE_BYTEORDER==4321 # define SQLITE_BIGENDIAN 1 |
︙ | ︙ | |||
17178 17179 17180 17181 17182 17183 17184 17185 17186 17187 17188 17189 17190 17191 | unsigned bUnordered:1; /* Use this index for == or IN queries only */ unsigned uniqNotNull:1; /* True if UNIQUE and NOT NULL for all columns */ unsigned isResized:1; /* True if resizeIndexObject() has been called */ unsigned isCovering:1; /* True if this is a covering index */ unsigned noSkipScan:1; /* Do not try to use skip-scan if true */ unsigned hasStat1:1; /* aiRowLogEst values come from sqlite_stat1 */ unsigned bNoQuery:1; /* Do not use this index to optimize queries */ #ifdef SQLITE_ENABLE_STAT3_OR_STAT4 int nSample; /* Number of elements in aSample[] */ int nSampleCol; /* Size of IndexSample.anEq[] and so on */ tRowcnt *aAvgEq; /* Average nEq values for keys not in aSample */ IndexSample *aSample; /* Samples of the left-most key */ tRowcnt *aiRowEst; /* Non-logarithmic stat1 data for this index */ tRowcnt nRowEst0; /* Non-logarithmic number of rows in the index */ | > | 17180 17181 17182 17183 17184 17185 17186 17187 17188 17189 17190 17191 17192 17193 17194 | unsigned bUnordered:1; /* Use this index for == or IN queries only */ unsigned uniqNotNull:1; /* True if UNIQUE and NOT NULL for all columns */ unsigned isResized:1; /* True if resizeIndexObject() has been called */ unsigned isCovering:1; /* True if this is a covering index */ unsigned noSkipScan:1; /* Do not try to use skip-scan if true */ unsigned hasStat1:1; /* aiRowLogEst values come from sqlite_stat1 */ unsigned bNoQuery:1; /* Do not use this index to optimize queries */ unsigned bAscKeyBug:1; /* True if the bba7b69f9849b5bf bug applies */ #ifdef SQLITE_ENABLE_STAT3_OR_STAT4 int nSample; /* Number of elements in aSample[] */ int nSampleCol; /* Size of IndexSample.anEq[] and so on */ tRowcnt *aAvgEq; /* Average nEq values for keys not in aSample */ IndexSample *aSample; /* Samples of the left-most key */ tRowcnt *aiRowEst; /* Non-logarithmic stat1 data for this index */ tRowcnt nRowEst0; /* Non-logarithmic number of rows in the index */ |
︙ | ︙ | |||
17405 17406 17407 17408 17409 17410 17411 | ** EP_Unlikely: 134217728 times likelihood ** TK_SELECT: 1st register of result vector */ ynVar iColumn; /* TK_COLUMN: column index. -1 for rowid. ** TK_VARIABLE: variable number (always >= 1). ** TK_SELECT_COLUMN: column of the result vector */ i16 iAgg; /* Which entry in pAggInfo->aCol[] or ->aFunc[] */ i16 iRightJoinTable; /* If EP_FromJoin, the right table of the join */ | | | 17408 17409 17410 17411 17412 17413 17414 17415 17416 17417 17418 17419 17420 17421 17422 | ** EP_Unlikely: 134217728 times likelihood ** TK_SELECT: 1st register of result vector */ ynVar iColumn; /* TK_COLUMN: column index. -1 for rowid. ** TK_VARIABLE: variable number (always >= 1). ** TK_SELECT_COLUMN: column of the result vector */ i16 iAgg; /* Which entry in pAggInfo->aCol[] or ->aFunc[] */ i16 iRightJoinTable; /* If EP_FromJoin, the right table of the join */ u8 op2; /* TK_REGISTER/TK_TRUTH: original value of Expr.op ** TK_COLUMN: the value of p5 for OP_Column ** TK_AGG_FUNCTION: nesting depth */ AggInfo *pAggInfo; /* Used by TK_AGG_COLUMN and TK_AGG_FUNCTION */ union { Table *pTab; /* TK_COLUMN: Table containing column. Can be NULL ** for a column of an index on an expression */ Window *pWin; /* TK_FUNCTION: Window definition for the func */ |
︙ | ︙ | |||
17690 17691 17692 17693 17694 17695 17696 | ExprList *pEList; /* Optional list of result-set columns */ AggInfo *pAggInfo; /* Information about aggregates at this level */ Upsert *pUpsert; /* ON CONFLICT clause information from an upsert */ } uNC; NameContext *pNext; /* Next outer name context. NULL for outermost */ int nRef; /* Number of names resolved by this context */ int nErr; /* Number of errors encountered while resolving names */ | | | 17693 17694 17695 17696 17697 17698 17699 17700 17701 17702 17703 17704 17705 17706 17707 | ExprList *pEList; /* Optional list of result-set columns */ AggInfo *pAggInfo; /* Information about aggregates at this level */ Upsert *pUpsert; /* ON CONFLICT clause information from an upsert */ } uNC; NameContext *pNext; /* Next outer name context. NULL for outermost */ int nRef; /* Number of names resolved by this context */ int nErr; /* Number of errors encountered while resolving names */ int ncFlags; /* Zero or more NC_* flags defined below */ Select *pWinSelect; /* SELECT statement for any window functions */ }; /* ** Allowed values for the NameContext, ncFlags field. ** ** Value constraints (all checked via assert()): |
︙ | ︙ | |||
17717 17718 17719 17720 17721 17722 17723 17724 17725 17726 17727 17728 17729 17730 | #define NC_UEList 0x0080 /* True if uNC.pEList is used */ #define NC_UAggInfo 0x0100 /* True if uNC.pAggInfo is used */ #define NC_UUpsert 0x0200 /* True if uNC.pUpsert is used */ #define NC_MinMaxAgg 0x1000 /* min/max aggregates seen. See note above */ #define NC_Complex 0x2000 /* True if a function or subquery seen */ #define NC_AllowWin 0x4000 /* Window functions are allowed here */ #define NC_HasWin 0x8000 /* One or more window functions seen */ /* ** An instance of the following object describes a single ON CONFLICT ** clause in an upsert. ** ** The pUpsertTarget field is only set if the ON CONFLICT clause includes ** conflict-target clause. (In "ON CONFLICT(a,b)" the "(a,b)" is the | > > | 17720 17721 17722 17723 17724 17725 17726 17727 17728 17729 17730 17731 17732 17733 17734 17735 | #define NC_UEList 0x0080 /* True if uNC.pEList is used */ #define NC_UAggInfo 0x0100 /* True if uNC.pAggInfo is used */ #define NC_UUpsert 0x0200 /* True if uNC.pUpsert is used */ #define NC_MinMaxAgg 0x1000 /* min/max aggregates seen. See note above */ #define NC_Complex 0x2000 /* True if a function or subquery seen */ #define NC_AllowWin 0x4000 /* Window functions are allowed here */ #define NC_HasWin 0x8000 /* One or more window functions seen */ #define NC_NoDblQStr 0x10000 /* Do not allow double-quoted string hack. ** Mnemonic: "NO DouBLe-Quoted STRings" */ /* ** An instance of the following object describes a single ON CONFLICT ** clause in an upsert. ** ** The pUpsertTarget field is only set if the ON CONFLICT clause includes ** conflict-target clause. (In "ON CONFLICT(a,b)" the "(a,b)" is the |
︙ | ︙ | |||
68716 68717 68718 68719 68720 68721 68722 68723 68724 68725 68726 68727 68728 68729 68730 68731 68732 | ** ** If the record is corrupt, the xRecordCompare routine may read ** up to two varints past the end of the buffer. An extra 18 ** bytes of padding is allocated at the end of the buffer in ** case this happens. */ void *pCellKey; u8 * const pCellBody = pCell - pPage->childPtrSize; pPage->xParseCell(pPage, pCellBody, &pCur->info); nCell = (int)pCur->info.nKey; testcase( nCell<0 ); /* True if key size is 2^32 or more */ testcase( nCell==0 ); /* Invalid key size: 0x80 0x80 0x00 */ testcase( nCell==1 ); /* Invalid key size: 0x80 0x80 0x01 */ testcase( nCell==2 ); /* Minimum legal index key size */ if( nCell<2 || nCell/pCur->pBt->usableSize>pCur->pBt->nPage ){ rc = SQLITE_CORRUPT_PAGE(pPage); goto moveto_finish; } | > | > | 68721 68722 68723 68724 68725 68726 68727 68728 68729 68730 68731 68732 68733 68734 68735 68736 68737 68738 68739 68740 68741 68742 68743 68744 68745 68746 68747 68748 68749 68750 68751 68752 68753 | ** ** If the record is corrupt, the xRecordCompare routine may read ** up to two varints past the end of the buffer. An extra 18 ** bytes of padding is allocated at the end of the buffer in ** case this happens. */ void *pCellKey; u8 * const pCellBody = pCell - pPage->childPtrSize; const int nOverrun = 18; /* Size of the overrun padding */ pPage->xParseCell(pPage, pCellBody, &pCur->info); nCell = (int)pCur->info.nKey; testcase( nCell<0 ); /* True if key size is 2^32 or more */ testcase( nCell==0 ); /* Invalid key size: 0x80 0x80 0x00 */ testcase( nCell==1 ); /* Invalid key size: 0x80 0x80 0x01 */ testcase( nCell==2 ); /* Minimum legal index key size */ if( nCell<2 || nCell/pCur->pBt->usableSize>pCur->pBt->nPage ){ rc = SQLITE_CORRUPT_PAGE(pPage); goto moveto_finish; } pCellKey = sqlite3Malloc( nCell+nOverrun ); if( pCellKey==0 ){ rc = SQLITE_NOMEM_BKPT; goto moveto_finish; } pCur->ix = (u16)idx; rc = accessPayload(pCur, 0, nCell, (unsigned char*)pCellKey, 0); memset(((u8*)pCellKey)+nCell,0,nOverrun); /* Fix uninit warnings */ pCur->curFlags &= ~BTCF_ValidOvfl; if( rc ){ sqlite3_free(pCellKey); goto moveto_finish; } c = sqlite3VdbeRecordCompare(nCell, pCellKey, pIdxKey); sqlite3_free(pCellKey); |
︙ | ︙ | |||
74558 74559 74560 74561 74562 74563 74564 | } assert( acc.zText==zBuf && acc.mxAlloc<=0 ); zBuf[acc.nChar] = 0; /* Fast version of sqlite3StrAccumFinish(&acc) */ } #ifdef SQLITE_DEBUG /* | > > | > | > > > > > > > > > > > | 74565 74566 74567 74568 74569 74570 74571 74572 74573 74574 74575 74576 74577 74578 74579 74580 74581 74582 74583 74584 74585 74586 74587 74588 74589 74590 74591 74592 74593 74594 74595 74596 74597 74598 74599 74600 74601 74602 74603 74604 74605 74606 74607 74608 74609 74610 74611 74612 74613 74614 74615 | } assert( acc.zText==zBuf && acc.mxAlloc<=0 ); zBuf[acc.nChar] = 0; /* Fast version of sqlite3StrAccumFinish(&acc) */ } #ifdef SQLITE_DEBUG /* ** Validity checks on pMem. pMem holds a string. ** ** (1) Check that string value of pMem agrees with its integer or real value. ** (2) Check that the string is correctly zero terminated ** ** A single int or real value always converts to the same strings. But ** many different strings can be converted into the same int or real. ** If a table contains a numeric value and an index is based on the ** corresponding string value, then it is important that the string be ** derived from the numeric value, not the other way around, to ensure ** that the index and table are consistent. See ticket ** https://www.sqlite.org/src/info/343634942dd54ab (2018-01-31) for ** an example. ** ** This routine looks at pMem to verify that if it has both a numeric ** representation and a string representation then the string rep has ** been derived from the numeric and not the other way around. It returns ** true if everything is ok and false if there is a problem. ** ** This routine is for use inside of assert() statements only. */ SQLITE_PRIVATE int sqlite3VdbeMemValidStrRep(Mem *p){ char zBuf[100]; char *z; int i, j, incr; if( (p->flags & MEM_Str)==0 ) return 1; if( p->flags & MEM_Term ){ /* Insure that the string is properly zero-terminated. Pay particular ** attention to the case where p->n is odd */ if( p->szMalloc>0 && p->z==p->zMalloc ){ assert( p->enc==SQLITE_UTF8 || p->szMalloc >= ((p->n+1)&~1)+2 ); assert( p->enc!=SQLITE_UTF8 || p->szMalloc >= p->n+1 ); } assert( p->z[p->n]==0 ); assert( p->enc==SQLITE_UTF8 || p->z[(p->n+1)&~1]==0 ); assert( p->enc==SQLITE_UTF8 || p->z[((p->n+1)&~1)+1]==0 ); } if( (p->flags & (MEM_Int|MEM_Real|MEM_IntReal))==0 ) return 1; vdbeMemRenderNum(sizeof(zBuf), zBuf, p); z = p->z; i = j = 0; incr = 1; if( p->enc!=SQLITE_UTF8 ){ incr = 2; |
︙ | ︙ | |||
75661 75662 75663 75664 75665 75666 75667 | }else{ sqlite3VdbeMemStringify(pVal, enc, 0); assert( 0==(1&SQLITE_PTR_TO_INT(pVal->z)) ); } assert(pVal->enc==(enc & ~SQLITE_UTF16_ALIGNED) || pVal->db==0 || pVal->db->mallocFailed ); if( pVal->enc==(enc & ~SQLITE_UTF16_ALIGNED) ){ | | | 75682 75683 75684 75685 75686 75687 75688 75689 75690 75691 75692 75693 75694 75695 75696 | }else{ sqlite3VdbeMemStringify(pVal, enc, 0); assert( 0==(1&SQLITE_PTR_TO_INT(pVal->z)) ); } assert(pVal->enc==(enc & ~SQLITE_UTF16_ALIGNED) || pVal->db==0 || pVal->db->mallocFailed ); if( pVal->enc==(enc & ~SQLITE_UTF16_ALIGNED) ){ assert( sqlite3VdbeMemValidStrRep(pVal) ); return pVal->z; }else{ return 0; } } /* This function is only available internally, it is not part of the |
︙ | ︙ | |||
75684 75685 75686 75687 75688 75689 75690 | */ SQLITE_PRIVATE const void *sqlite3ValueText(sqlite3_value* pVal, u8 enc){ if( !pVal ) return 0; assert( pVal->db==0 || sqlite3_mutex_held(pVal->db->mutex) ); assert( (enc&3)==(enc&~SQLITE_UTF16_ALIGNED) ); assert( !sqlite3VdbeMemIsRowSet(pVal) ); if( (pVal->flags&(MEM_Str|MEM_Term))==(MEM_Str|MEM_Term) && pVal->enc==enc ){ | | | 75705 75706 75707 75708 75709 75710 75711 75712 75713 75714 75715 75716 75717 75718 75719 | */ SQLITE_PRIVATE const void *sqlite3ValueText(sqlite3_value* pVal, u8 enc){ if( !pVal ) return 0; assert( pVal->db==0 || sqlite3_mutex_held(pVal->db->mutex) ); assert( (enc&3)==(enc&~SQLITE_UTF16_ALIGNED) ); assert( !sqlite3VdbeMemIsRowSet(pVal) ); if( (pVal->flags&(MEM_Str|MEM_Term))==(MEM_Str|MEM_Term) && pVal->enc==enc ){ assert( sqlite3VdbeMemValidStrRep(pVal) ); return pVal->z; } if( pVal->flags&MEM_Null ){ return 0; } return valueToText(pVal, enc); } |
︙ | ︙ | |||
76989 76990 76991 76992 76993 76994 76995 76996 76997 76998 76999 77000 77001 77002 77003 77004 77005 77006 77007 77008 77009 77010 77011 77012 77013 77014 77015 77016 77017 77018 77019 77020 77021 77022 77023 77024 77025 77026 77027 77028 | ** ** assert( sqlite3VdbeAssertMayAbort(pParse->pVdbe, pParse->mayAbort) ); */ SQLITE_PRIVATE int sqlite3VdbeAssertMayAbort(Vdbe *v, int mayAbort){ int hasAbort = 0; int hasFkCounter = 0; int hasCreateTable = 0; int hasInitCoroutine = 0; Op *pOp; VdbeOpIter sIter; memset(&sIter, 0, sizeof(sIter)); sIter.v = v; while( (pOp = opIterNext(&sIter))!=0 ){ int opcode = pOp->opcode; if( opcode==OP_Destroy || opcode==OP_VUpdate || opcode==OP_VRename || opcode==OP_VDestroy || (opcode==OP_Function0 && pOp->p4.pFunc->funcFlags&SQLITE_FUNC_INTERNAL) || ((opcode==OP_Halt || opcode==OP_HaltIfNull) && ((pOp->p1)!=SQLITE_OK && pOp->p2==OE_Abort)) ){ hasAbort = 1; break; } if( opcode==OP_CreateBtree && pOp->p3==BTREE_INTKEY ) hasCreateTable = 1; if( opcode==OP_InitCoroutine ) hasInitCoroutine = 1; #ifndef SQLITE_OMIT_FOREIGN_KEY if( opcode==OP_FkCounter && pOp->p1==0 && pOp->p2==1 ){ hasFkCounter = 1; } #endif } sqlite3DbFree(v->db, sIter.apSub); /* Return true if hasAbort==mayAbort. Or if a malloc failure occurred. ** If malloc failed, then the while() loop above may not have iterated ** through all opcodes and hasAbort may be set incorrectly. Return ** true for this case to prevent the assert() in the callers frame ** from failing. */ return ( v->db->mallocFailed || hasAbort==mayAbort || hasFkCounter | > > > > > > > > > | > | 77010 77011 77012 77013 77014 77015 77016 77017 77018 77019 77020 77021 77022 77023 77024 77025 77026 77027 77028 77029 77030 77031 77032 77033 77034 77035 77036 77037 77038 77039 77040 77041 77042 77043 77044 77045 77046 77047 77048 77049 77050 77051 77052 77053 77054 77055 77056 77057 77058 77059 77060 77061 77062 77063 77064 77065 77066 77067 | ** ** assert( sqlite3VdbeAssertMayAbort(pParse->pVdbe, pParse->mayAbort) ); */ SQLITE_PRIVATE int sqlite3VdbeAssertMayAbort(Vdbe *v, int mayAbort){ int hasAbort = 0; int hasFkCounter = 0; int hasCreateTable = 0; int hasCreateIndex = 0; int hasInitCoroutine = 0; Op *pOp; VdbeOpIter sIter; memset(&sIter, 0, sizeof(sIter)); sIter.v = v; while( (pOp = opIterNext(&sIter))!=0 ){ int opcode = pOp->opcode; if( opcode==OP_Destroy || opcode==OP_VUpdate || opcode==OP_VRename || opcode==OP_VDestroy || (opcode==OP_Function0 && pOp->p4.pFunc->funcFlags&SQLITE_FUNC_INTERNAL) || ((opcode==OP_Halt || opcode==OP_HaltIfNull) && ((pOp->p1)!=SQLITE_OK && pOp->p2==OE_Abort)) ){ hasAbort = 1; break; } if( opcode==OP_CreateBtree && pOp->p3==BTREE_INTKEY ) hasCreateTable = 1; if( mayAbort ){ /* hasCreateIndex may also be set for some DELETE statements that use ** OP_Clear. So this routine may end up returning true in the case ** where a "DELETE FROM tbl" has a statement-journal but does not ** require one. This is not so bad - it is an inefficiency, not a bug. */ if( opcode==OP_CreateBtree && pOp->p3==BTREE_BLOBKEY ) hasCreateIndex = 1; if( opcode==OP_Clear ) hasCreateIndex = 1; } if( opcode==OP_InitCoroutine ) hasInitCoroutine = 1; #ifndef SQLITE_OMIT_FOREIGN_KEY if( opcode==OP_FkCounter && pOp->p1==0 && pOp->p2==1 ){ hasFkCounter = 1; } #endif } sqlite3DbFree(v->db, sIter.apSub); /* Return true if hasAbort==mayAbort. Or if a malloc failure occurred. ** If malloc failed, then the while() loop above may not have iterated ** through all opcodes and hasAbort may be set incorrectly. Return ** true for this case to prevent the assert() in the callers frame ** from failing. */ return ( v->db->mallocFailed || hasAbort==mayAbort || hasFkCounter || (hasCreateTable && hasInitCoroutine) || hasCreateIndex ); } #endif /* SQLITE_DEBUG - the sqlite3AssertMayAbort() function */ #ifdef SQLITE_DEBUG /* ** Increment the nWrite counter in the VDBE if the cursor is not an ** ephemeral cursor, or if the cursor argument is NULL. |
︙ | ︙ | |||
85212 85213 85214 85215 85216 85217 85218 | if( sqlite3VdbeMemExpandBlob(pIn2) ) goto no_mem; flags2 = pIn2->flags & ~MEM_Str; } nByte = pIn1->n + pIn2->n; if( nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){ goto too_big; } | | > | 85243 85244 85245 85246 85247 85248 85249 85250 85251 85252 85253 85254 85255 85256 85257 85258 85259 85260 85261 85262 85263 85264 85265 85266 85267 85268 85269 85270 85271 | if( sqlite3VdbeMemExpandBlob(pIn2) ) goto no_mem; flags2 = pIn2->flags & ~MEM_Str; } nByte = pIn1->n + pIn2->n; if( nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){ goto too_big; } if( sqlite3VdbeMemGrow(pOut, (int)nByte+3, pOut==pIn2) ){ goto no_mem; } MemSetTypeFlag(pOut, MEM_Str); if( pOut!=pIn2 ){ memcpy(pOut->z, pIn2->z, pIn2->n); assert( (pIn2->flags & MEM_Dyn) == (flags2 & MEM_Dyn) ); pIn2->flags = flags2; } memcpy(&pOut->z[pIn2->n], pIn1->z, pIn1->n); assert( (pIn1->flags & MEM_Dyn) == (flags1 & MEM_Dyn) ); pIn1->flags = flags1; pOut->z[nByte]=0; pOut->z[nByte+1] = 0; pOut->z[nByte+2] = 0; pOut->flags |= MEM_Term; pOut->n = (int)nByte; pOut->enc = encoding; UPDATE_MAX_BLOBSIZE(pOut); break; } |
︙ | ︙ | |||
86594 86595 86596 86597 86598 86599 86600 86601 86602 86603 86604 86605 86606 86607 | /* Apply the requested affinity to all inputs */ assert( pData0<=pLast ); if( zAffinity ){ pRec = pData0; do{ applyAffinity(pRec, zAffinity[0], encoding); REGISTER_TRACE((int)(pRec-aMem), pRec); zAffinity++; pRec++; assert( zAffinity[0]==0 || pRec<=pLast ); }while( zAffinity[0] ); } | > > > > | 86626 86627 86628 86629 86630 86631 86632 86633 86634 86635 86636 86637 86638 86639 86640 86641 86642 86643 | /* Apply the requested affinity to all inputs */ assert( pData0<=pLast ); if( zAffinity ){ pRec = pData0; do{ applyAffinity(pRec, zAffinity[0], encoding); if( zAffinity[0]==SQLITE_AFF_REAL && (pRec->flags & MEM_Int) ){ pRec->flags |= MEM_IntReal; pRec->flags &= ~(MEM_Int); } REGISTER_TRACE((int)(pRec-aMem), pRec); zAffinity++; pRec++; assert( zAffinity[0]==0 || pRec<=pLast ); }while( zAffinity[0] ); } |
︙ | ︙ | |||
87712 87713 87714 87715 87716 87717 87718 87719 87720 87721 87722 87723 87724 87725 | oc = pOp->opcode; eqOnly = 0; pC->nullRow = 0; #ifdef SQLITE_DEBUG pC->seekOp = pOp->opcode; #endif if( pC->isTable ){ /* The BTREE_SEEK_EQ flag is only set on index cursors */ assert( sqlite3BtreeCursorHasHint(pC->uc.pCursor, BTREE_SEEK_EQ)==0 || CORRUPT_DB ); /* The input value in P3 might be of any type: integer, real, string, ** blob, or NULL. But it needs to be an integer before we can do | > > | 87748 87749 87750 87751 87752 87753 87754 87755 87756 87757 87758 87759 87760 87761 87762 87763 | oc = pOp->opcode; eqOnly = 0; pC->nullRow = 0; #ifdef SQLITE_DEBUG pC->seekOp = pOp->opcode; #endif pC->deferredMoveto = 0; pC->cacheStatus = CACHE_STALE; if( pC->isTable ){ /* The BTREE_SEEK_EQ flag is only set on index cursors */ assert( sqlite3BtreeCursorHasHint(pC->uc.pCursor, BTREE_SEEK_EQ)==0 || CORRUPT_DB ); /* The input value in P3 might be of any type: integer, real, string, ** blob, or NULL. But it needs to be an integer before we can do |
︙ | ︙ | |||
87816 87817 87818 87819 87820 87821 87822 | goto abort_due_to_error; } if( eqOnly && r.eqSeen==0 ){ assert( res!=0 ); goto seek_not_found; } } | < < | 87854 87855 87856 87857 87858 87859 87860 87861 87862 87863 87864 87865 87866 87867 | goto abort_due_to_error; } if( eqOnly && r.eqSeen==0 ){ assert( res!=0 ); goto seek_not_found; } } #ifdef SQLITE_TEST sqlite3_search_count++; #endif if( oc>=OP_SeekGE ){ assert( oc==OP_SeekGE || oc==OP_SeekGT ); if( res<0 || (res==0 && oc==OP_SeekGT) ){ res = 0; rc = sqlite3BtreeNext(pC->uc.pCursor, 0); |
︙ | ︙ | |||
88494 88495 88496 88497 88498 88499 88500 | #ifdef SQLITE_DEBUG if( pOp->p4type==P4_TABLE && HasRowid(pOp->p4.pTab) && pOp->p5==0 ){ /* If p5 is zero, the seek operation that positioned the cursor prior to ** OP_Delete will have also set the pC->movetoTarget field to the rowid of ** the row that is being deleted */ i64 iKey = sqlite3BtreeIntegerKey(pC->uc.pCursor); | | | 88530 88531 88532 88533 88534 88535 88536 88537 88538 88539 88540 88541 88542 88543 88544 | #ifdef SQLITE_DEBUG if( pOp->p4type==P4_TABLE && HasRowid(pOp->p4.pTab) && pOp->p5==0 ){ /* If p5 is zero, the seek operation that positioned the cursor prior to ** OP_Delete will have also set the pC->movetoTarget field to the rowid of ** the row that is being deleted */ i64 iKey = sqlite3BtreeIntegerKey(pC->uc.pCursor); assert( CORRUPT_DB || pC->movetoTarget==iKey ); } #endif /* If the update-hook or pre-update-hook will be invoked, set zDb to ** the name of the db to pass as to it. Also set local pTab to a copy ** of p4.pTab. Finally, if p5 is true, indicating that this cursor was ** last moved with OP_Next or OP_Prev, not Seek or NotFound, set |
︙ | ︙ | |||
95781 95782 95783 95784 95785 95786 95787 | ** pExpr. ** ** Because no reference was made to outer contexts, the pNC->nRef ** fields are not changed in any context. */ if( cnt==0 && zTab==0 ){ assert( pExpr->op==TK_ID ); | | > > | 95817 95818 95819 95820 95821 95822 95823 95824 95825 95826 95827 95828 95829 95830 95831 95832 95833 | ** pExpr. ** ** Because no reference was made to outer contexts, the pNC->nRef ** fields are not changed in any context. */ if( cnt==0 && zTab==0 ){ assert( pExpr->op==TK_ID ); if( ExprHasProperty(pExpr,EP_DblQuoted) && 0==(pTopNC->ncFlags&NC_NoDblQStr) ){ /* If a double-quoted identifier does not match any known column name, ** then treat it as a string. ** ** This hack was added in the early days of SQLite in a misguided attempt ** to be compatible with MySQL 3.x, which used double-quotes for strings. ** I now sorely regret putting in this hack. The effect of this hack is ** that misspelled identifier names are silently converted into strings |
︙ | ︙ | |||
96959 96960 96961 96962 96963 96964 96965 | ** An error message is left in pParse if anything is amiss. The number ** if errors is returned. */ SQLITE_PRIVATE int sqlite3ResolveExprNames( NameContext *pNC, /* Namespace to resolve expressions in. */ Expr *pExpr /* The expression to be analyzed. */ ){ | | | 96997 96998 96999 97000 97001 97002 97003 97004 97005 97006 97007 97008 97009 97010 97011 | ** An error message is left in pParse if anything is amiss. The number ** if errors is returned. */ SQLITE_PRIVATE int sqlite3ResolveExprNames( NameContext *pNC, /* Namespace to resolve expressions in. */ Expr *pExpr /* The expression to be analyzed. */ ){ int savedHasAgg; Walker w; if( pExpr==0 ) return SQLITE_OK; savedHasAgg = pNC->ncFlags & (NC_HasAgg|NC_MinMaxAgg|NC_HasWin); pNC->ncFlags &= ~(NC_HasAgg|NC_MinMaxAgg|NC_HasWin); w.pParse = pNC->pParse; w.xExprCallback = resolveExprStep; |
︙ | ︙ | |||
97074 97075 97076 97077 97078 97079 97080 97081 97082 97083 97084 97085 97086 97087 | sSrc.a[0].zName = pTab->zName; sSrc.a[0].pTab = pTab; sSrc.a[0].iCursor = -1; } sNC.pParse = pParse; sNC.pSrcList = &sSrc; sNC.ncFlags = type; if( (rc = sqlite3ResolveExprNames(&sNC, pExpr))!=SQLITE_OK ) return rc; if( pList ) rc = sqlite3ResolveExprListNames(&sNC, pList); return rc; } /************** End of resolve.c *********************************************/ /************** Begin file expr.c ********************************************/ | > > > | 97112 97113 97114 97115 97116 97117 97118 97119 97120 97121 97122 97123 97124 97125 97126 97127 97128 | sSrc.a[0].zName = pTab->zName; sSrc.a[0].pTab = pTab; sSrc.a[0].iCursor = -1; } sNC.pParse = pParse; sNC.pSrcList = &sSrc; sNC.ncFlags = type; if( !pParse->db->init.busy && !sqlite3WritableSchema(pParse->db) ){ sNC.ncFlags |= NC_NoDblQStr; } if( (rc = sqlite3ResolveExprNames(&sNC, pExpr))!=SQLITE_OK ) return rc; if( pList ) rc = sqlite3ResolveExprListNames(&sNC, pList); return rc; } /************** End of resolve.c *********************************************/ /************** Begin file expr.c ********************************************/ |
︙ | ︙ | |||
99891 99892 99893 99894 99895 99896 99897 99898 99899 99900 99901 99902 99903 99904 | /* If the expression is not constant then we will need to ** disable the test that was generated above that makes sure ** this code only executes once. Because for a non-constant ** expression we need to rerun this code each time. */ if( addrOnce && !sqlite3ExprIsConstant(pE2) ){ sqlite3VdbeChangeToNoop(v, addrOnce); addrOnce = 0; } /* Evaluate the expression and insert it into the temp table */ r3 = sqlite3ExprCodeTarget(pParse, pE2, r1); sqlite3VdbeAddOp4(v, OP_MakeRecord, r3, 1, r2, &affinity, 1); sqlite3VdbeAddOp4Int(v, OP_IdxInsert, iTab, r2, r3, 1); | > | 99932 99933 99934 99935 99936 99937 99938 99939 99940 99941 99942 99943 99944 99945 99946 | /* If the expression is not constant then we will need to ** disable the test that was generated above that makes sure ** this code only executes once. Because for a non-constant ** expression we need to rerun this code each time. */ if( addrOnce && !sqlite3ExprIsConstant(pE2) ){ sqlite3VdbeChangeToNoop(v, addrOnce); ExprClearProperty(pExpr, EP_Subrtn); addrOnce = 0; } /* Evaluate the expression and insert it into the temp table */ r3 = sqlite3ExprCodeTarget(pParse, pE2, r1); sqlite3VdbeAddOp4(v, OP_MakeRecord, r3, 1, r2, &affinity, 1); sqlite3VdbeAddOp4Int(v, OP_IdxInsert, iTab, r2, r3, 1); |
︙ | ︙ | |||
101944 101945 101946 101947 101948 101949 101950 101951 101952 101953 101954 101955 101956 101957 | if( sqlite3ExprCompare(pParse, pA->pRight, pB->pRight, iTab) ) return 2; if( sqlite3ExprListCompare(pA->x.pList, pB->x.pList, iTab) ) return 2; if( pA->op!=TK_STRING && pA->op!=TK_TRUEFALSE && (combinedFlags & EP_Reduced)==0 ){ if( pA->iColumn!=pB->iColumn ) return 2; if( pA->iTable!=pB->iTable && (pA->iTable!=iTab || NEVER(pB->iTable>=0)) ) return 2; } } return 0; } | > | 101986 101987 101988 101989 101990 101991 101992 101993 101994 101995 101996 101997 101998 101999 102000 | if( sqlite3ExprCompare(pParse, pA->pRight, pB->pRight, iTab) ) return 2; if( sqlite3ExprListCompare(pA->x.pList, pB->x.pList, iTab) ) return 2; if( pA->op!=TK_STRING && pA->op!=TK_TRUEFALSE && (combinedFlags & EP_Reduced)==0 ){ if( pA->iColumn!=pB->iColumn ) return 2; if( pA->op2!=pB->op2 ) return 2; if( pA->iTable!=pB->iTable && (pA->iTable!=iTab || NEVER(pB->iTable>=0)) ) return 2; } } return 0; } |
︙ | ︙ | |||
101990 101991 101992 101993 101994 101995 101996 101997 101998 101999 102000 102001 102002 102003 | */ SQLITE_PRIVATE int sqlite3ExprCompareSkip(Expr *pA, Expr *pB, int iTab){ return sqlite3ExprCompare(0, sqlite3ExprSkipCollate(pA), sqlite3ExprSkipCollate(pB), iTab); } /* ** Return true if we can prove the pE2 will always be true if pE1 is ** true. Return false if we cannot complete the proof or if pE2 might ** be false. Examples: ** ** pE1: x==5 pE2: x==5 Result: true | > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 102033 102034 102035 102036 102037 102038 102039 102040 102041 102042 102043 102044 102045 102046 102047 102048 102049 102050 102051 102052 102053 102054 102055 102056 102057 102058 102059 102060 102061 102062 102063 102064 102065 102066 102067 102068 102069 102070 102071 102072 102073 102074 102075 102076 102077 102078 102079 102080 102081 102082 102083 102084 102085 102086 102087 102088 102089 102090 102091 102092 102093 102094 102095 102096 102097 102098 102099 102100 102101 102102 102103 102104 102105 102106 102107 102108 102109 102110 102111 102112 102113 102114 102115 102116 | */ SQLITE_PRIVATE int sqlite3ExprCompareSkip(Expr *pA, Expr *pB, int iTab){ return sqlite3ExprCompare(0, sqlite3ExprSkipCollate(pA), sqlite3ExprSkipCollate(pB), iTab); } /* ** Return non-zero if Expr p can only be true if pNN is not NULL. */ static int exprImpliesNotNull( Parse *pParse, /* Parsing context */ Expr *p, /* The expression to be checked */ Expr *pNN, /* The expression that is NOT NULL */ int iTab, /* Table being evaluated */ int seenNot /* True if p is an operand of NOT */ ){ assert( p ); assert( pNN ); if( sqlite3ExprCompare(pParse, p, pNN, iTab)==0 ) return 1; switch( p->op ){ case TK_IN: { if( seenNot && ExprHasProperty(p, EP_xIsSelect) ) return 0; assert( ExprHasProperty(p,EP_xIsSelect) || (p->x.pList!=0 && p->x.pList->nExpr>0) ); return exprImpliesNotNull(pParse, p->pLeft, pNN, iTab, seenNot); } case TK_BETWEEN: { ExprList *pList = p->x.pList; assert( pList!=0 ); assert( pList->nExpr==2 ); if( seenNot ) return 0; if( exprImpliesNotNull(pParse, pList->a[0].pExpr, pNN, iTab, seenNot) || exprImpliesNotNull(pParse, pList->a[1].pExpr, pNN, iTab, seenNot) ){ return 1; } return exprImpliesNotNull(pParse, p->pLeft, pNN, iTab, seenNot); } case TK_EQ: case TK_NE: case TK_LT: case TK_LE: case TK_GT: case TK_GE: case TK_PLUS: case TK_MINUS: case TK_STAR: case TK_REM: case TK_BITAND: case TK_BITOR: case TK_SLASH: case TK_LSHIFT: case TK_RSHIFT: case TK_CONCAT: { if( exprImpliesNotNull(pParse, p->pRight, pNN, iTab, seenNot) ) return 1; /* Fall thru into the next case */ } case TK_SPAN: case TK_COLLATE: case TK_BITNOT: case TK_UPLUS: case TK_UMINUS: { return exprImpliesNotNull(pParse, p->pLeft, pNN, iTab, seenNot); } case TK_TRUTH: { if( seenNot ) return 0; if( p->op2!=TK_IS ) return 0; return exprImpliesNotNull(pParse, p->pLeft, pNN, iTab, seenNot); } case TK_NOT: { return exprImpliesNotNull(pParse, p->pLeft, pNN, iTab, 1); } } return 0; } /* ** Return true if we can prove the pE2 will always be true if pE1 is ** true. Return false if we cannot complete the proof or if pE2 might ** be false. Examples: ** ** pE1: x==5 pE2: x==5 Result: true |
︙ | ︙ | |||
102027 102028 102029 102030 102031 102032 102033 | if( pE2->op==TK_OR && (sqlite3ExprImpliesExpr(pParse, pE1, pE2->pLeft, iTab) || sqlite3ExprImpliesExpr(pParse, pE1, pE2->pRight, iTab) ) ){ return 1; } if( pE2->op==TK_NOTNULL | | < < < < | | 102140 102141 102142 102143 102144 102145 102146 102147 102148 102149 102150 102151 102152 102153 102154 102155 102156 | if( pE2->op==TK_OR && (sqlite3ExprImpliesExpr(pParse, pE1, pE2->pLeft, iTab) || sqlite3ExprImpliesExpr(pParse, pE1, pE2->pRight, iTab) ) ){ return 1; } if( pE2->op==TK_NOTNULL && exprImpliesNotNull(pParse, pE1, pE2->pLeft, iTab, 0) ){ return 1; } return 0; } /* ** This is the Expr node callback for sqlite3ExprImpliesNotNullRow(). ** If the expression node requires that the table at pWalker->iCur |
︙ | ︙ | |||
108977 108978 108979 108980 108981 108982 108983 108984 108985 108986 108987 108988 108989 108990 | } if( resizeIndexObject(db, pIdx, pIdx->nKeyCol+n) ) return; for(i=0, j=pIdx->nKeyCol; i<nPk; i++){ if( !isDupColumn(pIdx, pIdx->nKeyCol, pPk, i) ){ testcase( hasColumn(pIdx->aiColumn, pIdx->nKeyCol, pPk->aiColumn[i]) ); pIdx->aiColumn[j] = pPk->aiColumn[i]; pIdx->azColl[j] = pPk->azColl[i]; j++; } } assert( pIdx->nColumn>=pIdx->nKeyCol+n ); assert( pIdx->nColumn>=j ); } | > > > > | 109086 109087 109088 109089 109090 109091 109092 109093 109094 109095 109096 109097 109098 109099 109100 109101 109102 109103 | } if( resizeIndexObject(db, pIdx, pIdx->nKeyCol+n) ) return; for(i=0, j=pIdx->nKeyCol; i<nPk; i++){ if( !isDupColumn(pIdx, pIdx->nKeyCol, pPk, i) ){ testcase( hasColumn(pIdx->aiColumn, pIdx->nKeyCol, pPk->aiColumn[i]) ); pIdx->aiColumn[j] = pPk->aiColumn[i]; pIdx->azColl[j] = pPk->azColl[i]; if( pPk->aSortOrder[i] ){ /* See ticket https://www.sqlite.org/src/info/bba7b69f9849b5bf */ pIdx->bAscKeyBug = 1; } j++; } } assert( pIdx->nColumn>=pIdx->nKeyCol+n ); assert( pIdx->nColumn>=j ); } |
︙ | ︙ | |||
110095 110096 110097 110098 110099 110100 110101 110102 110103 110104 | addr2 = sqlite3VdbeCurrentAddr(v); sqlite3VdbeVerifyAbortable(v, OE_Abort); sqlite3VdbeAddOp4Int(v, OP_SorterCompare, iSorter, j2, regRecord, pIndex->nKeyCol); VdbeCoverage(v); sqlite3UniqueConstraint(pParse, OE_Abort, pIndex); sqlite3VdbeJumpHere(v, j2); }else{ addr2 = sqlite3VdbeCurrentAddr(v); } sqlite3VdbeAddOp3(v, OP_SorterData, iSorter, regRecord, iIdx); | > > > > > > > > > > > > > > > > | > | 110208 110209 110210 110211 110212 110213 110214 110215 110216 110217 110218 110219 110220 110221 110222 110223 110224 110225 110226 110227 110228 110229 110230 110231 110232 110233 110234 110235 110236 110237 110238 110239 110240 110241 110242 | addr2 = sqlite3VdbeCurrentAddr(v); sqlite3VdbeVerifyAbortable(v, OE_Abort); sqlite3VdbeAddOp4Int(v, OP_SorterCompare, iSorter, j2, regRecord, pIndex->nKeyCol); VdbeCoverage(v); sqlite3UniqueConstraint(pParse, OE_Abort, pIndex); sqlite3VdbeJumpHere(v, j2); }else{ /* Most CREATE INDEX and REINDEX statements that are not UNIQUE can not ** abort. The exception is if one of the indexed expressions contains a ** user function that throws an exception when it is evaluated. But the ** overhead of adding a statement journal to a CREATE INDEX statement is ** very small (since most of the pages written do not contain content that ** needs to be restored if the statement aborts), so we call ** sqlite3MayAbort() for all CREATE INDEX statements. */ sqlite3MayAbort(pParse); addr2 = sqlite3VdbeCurrentAddr(v); } sqlite3VdbeAddOp3(v, OP_SorterData, iSorter, regRecord, iIdx); if( !pIndex->bAscKeyBug ){ /* This OP_SeekEnd opcode makes index insert for a REINDEX go much ** faster by avoiding unnecessary seeks. But the optimization does ** not work for UNIQUE constraint indexes on WITHOUT ROWID tables ** with DESC primary keys, since those indexes have there keys in ** a different order from the main table. ** See ticket: https://www.sqlite.org/src/info/bba7b69f9849b5bf */ sqlite3VdbeAddOp1(v, OP_SeekEnd, iIdx); } sqlite3VdbeAddOp2(v, OP_IdxInsert, iIdx, regRecord); sqlite3VdbeChangeP5(v, OPFLAG_USESEEKRESULT); sqlite3ReleaseTempReg(pParse, regRecord); sqlite3VdbeAddOp2(v, OP_SorterNext, iSorter, addr2); VdbeCoverage(v); sqlite3VdbeJumpHere(v, addr1); sqlite3VdbeAddOp1(v, OP_Close, iTab); |
︙ | ︙ | |||
120848 120849 120850 120851 120852 120853 120854 | #define PragTyp_TABLE_INFO 34 #define PragTyp_TEMP_STORE 35 #define PragTyp_TEMP_STORE_DIRECTORY 36 #define PragTyp_THREADS 37 #define PragTyp_WAL_AUTOCHECKPOINT 38 #define PragTyp_WAL_CHECKPOINT 39 #define PragTyp_ACTIVATE_EXTENSIONS 40 | < | | | | 120978 120979 120980 120981 120982 120983 120984 120985 120986 120987 120988 120989 120990 120991 120992 120993 120994 | #define PragTyp_TABLE_INFO 34 #define PragTyp_TEMP_STORE 35 #define PragTyp_TEMP_STORE_DIRECTORY 36 #define PragTyp_THREADS 37 #define PragTyp_WAL_AUTOCHECKPOINT 38 #define PragTyp_WAL_CHECKPOINT 39 #define PragTyp_ACTIVATE_EXTENSIONS 40 #define PragTyp_KEY 41 #define PragTyp_LOCK_STATUS 42 #define PragTyp_STATS 43 /* Property flags associated with various pragma. */ #define PragFlg_NeedSchema 0x01 /* Force schema load before running */ #define PragFlg_NoColumns 0x02 /* OP_ResultRow called with zero columns */ #define PragFlg_NoColumns1 0x04 /* zero columns if RHS argument is present */ #define PragFlg_ReadOnly 0x08 /* Read-only HEADER_VALUE */ #define PragFlg_Result0 0x10 /* Acts as query when no argument */ |
︙ | ︙ | |||
121124 121125 121126 121127 121128 121129 121130 | /* ePragFlg: */ PragFlg_Result0, /* ColNames: */ 41, 2, /* iArg: */ 0 }, #endif #endif #if defined(SQLITE_HAS_CODEC) {/* zName: */ "hexkey", | | | | 121253 121254 121255 121256 121257 121258 121259 121260 121261 121262 121263 121264 121265 121266 121267 121268 121269 121270 121271 121272 | /* ePragFlg: */ PragFlg_Result0, /* ColNames: */ 41, 2, /* iArg: */ 0 }, #endif #endif #if defined(SQLITE_HAS_CODEC) {/* zName: */ "hexkey", /* ePragTyp: */ PragTyp_KEY, /* ePragFlg: */ 0, /* ColNames: */ 0, 0, /* iArg: */ 2 }, {/* zName: */ "hexrekey", /* ePragTyp: */ PragTyp_KEY, /* ePragFlg: */ 0, /* ColNames: */ 0, 0, /* iArg: */ 3 }, #endif #if !defined(SQLITE_OMIT_FLAG_PRAGMAS) #if !defined(SQLITE_OMIT_CHECK) {/* zName: */ "ignore_check_constraints", |
︙ | ︙ | |||
122089 122090 122091 122092 122093 122094 122095 122096 122097 122098 122099 122100 122101 122102 | for(eMode=0; (zMode = sqlite3JournalModename(eMode))!=0; eMode++){ if( sqlite3StrNICmp(zRight, zMode, n)==0 ) break; } if( !zMode ){ /* If the "=MODE" part does not match any known journal mode, ** then do a query */ eMode = PAGER_JOURNALMODE_QUERY; } } if( eMode==PAGER_JOURNALMODE_QUERY && pId2->n==0 ){ /* Convert "PRAGMA journal_mode" into "PRAGMA main.journal_mode" */ iDb = 0; pId2->n = 1; } | > > > > > | 122218 122219 122220 122221 122222 122223 122224 122225 122226 122227 122228 122229 122230 122231 122232 122233 122234 122235 122236 | for(eMode=0; (zMode = sqlite3JournalModename(eMode))!=0; eMode++){ if( sqlite3StrNICmp(zRight, zMode, n)==0 ) break; } if( !zMode ){ /* If the "=MODE" part does not match any known journal mode, ** then do a query */ eMode = PAGER_JOURNALMODE_QUERY; } if( eMode==PAGER_JOURNALMODE_OFF && (db->flags & SQLITE_Defensive)!=0 ){ /* Do not allow journal-mode "OFF" in defensive since the database ** can become corrupted using ordinary SQL when the journal is off */ eMode = PAGER_JOURNALMODE_QUERY; } } if( eMode==PAGER_JOURNALMODE_QUERY && pId2->n==0 ){ /* Convert "PRAGMA journal_mode" into "PRAGMA main.journal_mode" */ iDb = 0; pId2->n = 1; } |
︙ | ︙ | |||
123571 123572 123573 123574 123575 123576 123577 | ** hexkey 2 ** hexrekey 3 ** textkey 4 ** textrekey 5 */ case PragTyp_KEY: { if( zRight ){ | > > | | < < < < < < < < < | | < | | | | > > > > > | | > > > > > | 123705 123706 123707 123708 123709 123710 123711 123712 123713 123714 123715 123716 123717 123718 123719 123720 123721 123722 123723 123724 123725 123726 123727 123728 123729 123730 123731 123732 123733 123734 123735 123736 123737 123738 123739 123740 123741 123742 | ** hexkey 2 ** hexrekey 3 ** textkey 4 ** textrekey 5 */ case PragTyp_KEY: { if( zRight ){ char zBuf[40]; const char *zKey = zRight; int n; if( pPragma->iArg==2 || pPragma->iArg==3 ){ u8 iByte; int i; for(i=0, iByte=0; i<sizeof(zBuf)*2 && sqlite3Isxdigit(zRight[i]); i++){ iByte = (iByte<<4) + sqlite3HexToInt(zRight[i]); if( (i&1)!=0 ) zBuf[i/2] = iByte; } zKey = zBuf; n = i/2; }else{ n = pPragma->iArg<4 ? sqlite3Strlen30(zRight) : -1; } if( (pPragma->iArg & 1)==0 ){ rc = sqlite3_key_v2(db, zDb, zKey, n); }else{ rc = sqlite3_rekey_v2(db, zDb, zKey, n); } if( rc==SQLITE_OK && n!=0 ){ sqlite3VdbeSetNumCols(v, 1); sqlite3VdbeSetColName(v, 0, COLNAME_NAME, "ok", SQLITE_STATIC); returnSingleText(v, "ok"); } } break; } #endif #if defined(SQLITE_HAS_CODEC) || defined(SQLITE_ENABLE_CEROD) case PragTyp_ACTIVATE_EXTENSIONS: if( zRight ){ |
︙ | ︙ | |||
129721 129722 129723 129724 129725 129726 129727 129728 129729 129730 129731 129732 129733 129734 | if( db->mallocFailed ){ return WRC_Abort; } assert( p->pSrc!=0 ); if( (selFlags & SF_Expanded)!=0 ){ return WRC_Prune; } pTabList = p->pSrc; pEList = p->pEList; sqlite3WithPush(pParse, p->pWith, 0); /* Make sure cursor numbers have been assigned to all entries in ** the FROM clause of the SELECT statement. */ | > > > > | 129857 129858 129859 129860 129861 129862 129863 129864 129865 129866 129867 129868 129869 129870 129871 129872 129873 129874 | if( db->mallocFailed ){ return WRC_Abort; } assert( p->pSrc!=0 ); if( (selFlags & SF_Expanded)!=0 ){ return WRC_Prune; } if( pWalker->eCode ){ /* Renumber selId because it has been copied from a view */ p->selId = ++pParse->nSelect; } pTabList = p->pSrc; pEList = p->pEList; sqlite3WithPush(pParse, p->pWith, 0); /* Make sure cursor numbers have been assigned to all entries in ** the FROM clause of the SELECT statement. */ |
︙ | ︙ | |||
129770 129771 129772 129773 129774 129775 129776 129777 129778 129779 129780 129781 129782 129783 129784 129785 129786 129787 129788 129789 | pTab->nTabRef++; if( !IsVirtual(pTab) && cannotBeFunction(pParse, pFrom) ){ return WRC_Abort; } #if !defined(SQLITE_OMIT_VIEW) || !defined (SQLITE_OMIT_VIRTUALTABLE) if( IsVirtual(pTab) || pTab->pSelect ){ i16 nCol; if( sqlite3ViewGetColumnNames(pParse, pTab) ) return WRC_Abort; assert( pFrom->pSelect==0 ); pFrom->pSelect = sqlite3SelectDup(db, pTab->pSelect, 0); nCol = pTab->nCol; pTab->nCol = -1; sqlite3WalkSelect(pWalker, pFrom->pSelect); pTab->nCol = nCol; } #endif } /* Locate the index named by the INDEXED BY clause, if any. */ if( sqlite3IndexedByLookup(pParse, pFrom) ){ | > > > | 129910 129911 129912 129913 129914 129915 129916 129917 129918 129919 129920 129921 129922 129923 129924 129925 129926 129927 129928 129929 129930 129931 129932 | pTab->nTabRef++; if( !IsVirtual(pTab) && cannotBeFunction(pParse, pFrom) ){ return WRC_Abort; } #if !defined(SQLITE_OMIT_VIEW) || !defined (SQLITE_OMIT_VIRTUALTABLE) if( IsVirtual(pTab) || pTab->pSelect ){ i16 nCol; u8 eCodeOrig = pWalker->eCode; if( sqlite3ViewGetColumnNames(pParse, pTab) ) return WRC_Abort; assert( pFrom->pSelect==0 ); pFrom->pSelect = sqlite3SelectDup(db, pTab->pSelect, 0); nCol = pTab->nCol; pTab->nCol = -1; pWalker->eCode = 1; /* Turn on Select.selId renumbering */ sqlite3WalkSelect(pWalker, pFrom->pSelect); pWalker->eCode = eCodeOrig; pTab->nCol = nCol; } #endif } /* Locate the index named by the INDEXED BY clause, if any. */ if( sqlite3IndexedByLookup(pParse, pFrom) ){ |
︙ | ︙ | |||
130025 130026 130027 130028 130029 130030 130031 130032 130033 130034 130035 130036 130037 130038 | if( OK_IF_ALWAYS_TRUE(pParse->hasCompound) ){ w.xSelectCallback = convertCompoundSelectToSubquery; w.xSelectCallback2 = 0; sqlite3WalkSelect(&w, pSelect); } w.xSelectCallback = selectExpander; w.xSelectCallback2 = selectPopWith; sqlite3WalkSelect(&w, pSelect); } #ifndef SQLITE_OMIT_SUBQUERY /* ** This is a Walker.xSelectCallback callback for the sqlite3SelectTypeInfo() | > | 130168 130169 130170 130171 130172 130173 130174 130175 130176 130177 130178 130179 130180 130181 130182 | if( OK_IF_ALWAYS_TRUE(pParse->hasCompound) ){ w.xSelectCallback = convertCompoundSelectToSubquery; w.xSelectCallback2 = 0; sqlite3WalkSelect(&w, pSelect); } w.xSelectCallback = selectExpander; w.xSelectCallback2 = selectPopWith; w.eCode = 0; sqlite3WalkSelect(&w, pSelect); } #ifndef SQLITE_OMIT_SUBQUERY /* ** This is a Walker.xSelectCallback callback for the sqlite3SelectTypeInfo() |
︙ | ︙ | |||
130351 130352 130353 130354 130355 130356 130357 | ){ struct SrcList_item *pItem; for(pItem = pTabList->a; pItem<pThis; pItem++){ Select *pS1; if( pItem->pSelect==0 ) continue; if( pItem->fg.viaCoroutine ) continue; if( pItem->zName==0 ) continue; | > | > | | 130495 130496 130497 130498 130499 130500 130501 130502 130503 130504 130505 130506 130507 130508 130509 130510 130511 130512 130513 130514 | ){ struct SrcList_item *pItem; for(pItem = pTabList->a; pItem<pThis; pItem++){ Select *pS1; if( pItem->pSelect==0 ) continue; if( pItem->fg.viaCoroutine ) continue; if( pItem->zName==0 ) continue; assert( pItem->pTab!=0 ); assert( pThis->pTab!=0 ); if( pItem->pTab->pSchema!=pThis->pTab->pSchema ) continue; if( sqlite3_stricmp(pItem->zName, pThis->zName)!=0 ) continue; pS1 = pItem->pSelect; if( pItem->pTab->pSchema==0 && pThis->pSelect->selId!=pS1->selId ){ /* The query flattener left two different CTE tables with identical ** names in the same FROM clause. */ continue; } if( sqlite3ExprCompare(0, pThis->pSelect->pWhere, pS1->pWhere, -1) || sqlite3ExprCompare(0, pThis->pSelect->pHaving, pS1->pHaving, -1) ){ |
︙ | ︙ | |||
130386 130387 130388 130389 130390 130391 130392 | ** SELECT (SELECT count(*) FROM t1)+(SELECT count(*) FROM t2) ** ** The transformation only works if all of the following are true: ** ** * The subquery is a UNION ALL of two or more terms ** * The subquery does not have a LIMIT clause ** * There is no WHERE or GROUP BY or HAVING clauses on the subqueries | | > > > | 130532 130533 130534 130535 130536 130537 130538 130539 130540 130541 130542 130543 130544 130545 130546 130547 130548 130549 130550 130551 130552 130553 130554 130555 130556 130557 130558 130559 | ** SELECT (SELECT count(*) FROM t1)+(SELECT count(*) FROM t2) ** ** The transformation only works if all of the following are true: ** ** * The subquery is a UNION ALL of two or more terms ** * The subquery does not have a LIMIT clause ** * There is no WHERE or GROUP BY or HAVING clauses on the subqueries ** * The outer query is a simple count(*) with no WHERE clause or other ** extraneous syntax. ** ** Return TRUE if the optimization is undertaken. */ static int countOfViewOptimization(Parse *pParse, Select *p){ Select *pSub, *pPrior; Expr *pExpr; Expr *pCount; sqlite3 *db; if( (p->selFlags & SF_Aggregate)==0 ) return 0; /* This is an aggregate */ if( p->pEList->nExpr!=1 ) return 0; /* Single result column */ if( p->pWhere ) return 0; if( p->pGroupBy ) return 0; pExpr = p->pEList->a[0].pExpr; if( pExpr->op!=TK_AGG_FUNCTION ) return 0; /* Result is an aggregate */ if( sqlite3_stricmp(pExpr->u.zToken,"count") ) return 0; /* Is count() */ if( pExpr->x.pList!=0 ) return 0; /* Must be count(*) */ if( p->pSrc->nSrc!=1 ) return 0; /* One table in FROM */ pSub = p->pSrc->a[0].pSelect; if( pSub==0 ) return 0; /* The FROM is a subquery */ |
︙ | ︙ | |||
148648 148649 148650 148651 148652 148653 148654 | ** YY_MAX_REDUCE Maximum value for reduce actions */ #ifndef INTERFACE # define INTERFACE 1 #endif /************* Begin control #defines *****************************************/ #define YYCODETYPE unsigned short int | | | | | | > > | | | > | | < < | | < | | | | | | | 148797 148798 148799 148800 148801 148802 148803 148804 148805 148806 148807 148808 148809 148810 148811 148812 148813 148814 148815 148816 148817 148818 148819 148820 148821 148822 148823 148824 148825 148826 148827 148828 148829 148830 148831 148832 148833 148834 148835 148836 148837 148838 148839 148840 148841 148842 148843 148844 148845 148846 148847 148848 148849 148850 148851 148852 148853 148854 148855 148856 148857 148858 | ** YY_MAX_REDUCE Maximum value for reduce actions */ #ifndef INTERFACE # define INTERFACE 1 #endif /************* Begin control #defines *****************************************/ #define YYCODETYPE unsigned short int #define YYNOCODE 302 #define YYACTIONTYPE unsigned short int #define YYWILDCARD 95 #define sqlite3ParserTOKENTYPE Token typedef union { int yyinit; sqlite3ParserTOKENTYPE yy0; TriggerStep* yy11; IdList* yy76; ExprList* yy94; Upsert* yy95; int yy100; Expr* yy102; struct {int value; int mask;} yy199; u8 yy218; With* yy243; struct TrigEvent yy298; Window* yy379; struct FrameBound yy389; Select* yy391; SrcList* yy407; const char* yy528; } YYMINORTYPE; #ifndef YYSTACKDEPTH #define YYSTACKDEPTH 100 #endif #define sqlite3ParserARG_SDECL #define sqlite3ParserARG_PDECL #define sqlite3ParserARG_PARAM #define sqlite3ParserARG_FETCH #define sqlite3ParserARG_STORE #define sqlite3ParserCTX_SDECL Parse *pParse; #define sqlite3ParserCTX_PDECL ,Parse *pParse #define sqlite3ParserCTX_PARAM ,pParse #define sqlite3ParserCTX_FETCH Parse *pParse=yypParser->pParse; #define sqlite3ParserCTX_STORE yypParser->pParse=pParse; #define YYFALLBACK 1 #define YYNSTATE 540 #define YYNRULE 376 #define YYNTOKEN 176 #define YY_MAX_SHIFT 539 #define YY_MIN_SHIFTREDUCE 783 #define YY_MAX_SHIFTREDUCE 1158 #define YY_ERROR_ACTION 1159 #define YY_ACCEPT_ACTION 1160 #define YY_NO_ACTION 1161 #define YY_MIN_REDUCE 1162 #define YY_MAX_REDUCE 1537 /************* End control #defines *******************************************/ #define YY_NLOOKAHEAD ((int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0]))) /* Define the yytestcase() macro to be a no-op if is not already defined ** otherwise. ** ** Applications can choose to define yytestcase() in the %include section |
︙ | ︙ | |||
148764 148765 148766 148767 148768 148769 148770 | ** yy_reduce_ofst[] For each state, the offset into yy_action for ** shifting non-terminals after a reduce. ** yy_default[] Default action for each state. ** *********** Begin parsing tables **********************************************/ #define YY_ACTTAB_COUNT (2142) static const YYACTIONTYPE yy_action[] = { | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | 148913 148914 148915 148916 148917 148918 148919 148920 148921 148922 148923 148924 148925 148926 148927 148928 148929 148930 148931 148932 148933 148934 148935 148936 148937 148938 148939 148940 148941 148942 148943 148944 148945 148946 148947 148948 148949 148950 148951 148952 148953 148954 148955 148956 148957 148958 148959 148960 148961 148962 148963 148964 148965 148966 148967 148968 148969 148970 148971 148972 148973 148974 148975 148976 148977 148978 148979 148980 148981 148982 148983 148984 148985 148986 148987 148988 148989 148990 148991 148992 148993 148994 148995 148996 148997 148998 148999 149000 149001 149002 149003 149004 149005 149006 149007 149008 149009 149010 149011 149012 149013 149014 149015 149016 149017 149018 149019 149020 149021 149022 149023 149024 149025 149026 149027 149028 149029 149030 149031 149032 149033 149034 149035 149036 149037 149038 149039 149040 149041 149042 149043 149044 149045 149046 149047 149048 149049 149050 149051 149052 149053 149054 149055 149056 149057 149058 149059 149060 149061 149062 149063 149064 149065 149066 149067 149068 149069 149070 149071 149072 149073 149074 149075 149076 149077 149078 149079 149080 149081 149082 149083 149084 149085 149086 149087 149088 149089 149090 149091 149092 149093 149094 149095 149096 149097 149098 149099 149100 149101 149102 149103 149104 149105 149106 149107 149108 149109 149110 149111 149112 149113 149114 149115 149116 149117 149118 149119 149120 149121 149122 149123 149124 149125 149126 149127 149128 149129 149130 149131 149132 149133 149134 149135 149136 149137 149138 149139 149140 149141 149142 149143 149144 149145 149146 149147 149148 149149 149150 149151 149152 149153 149154 149155 149156 149157 149158 149159 149160 149161 149162 149163 149164 149165 149166 149167 149168 149169 149170 149171 149172 149173 149174 149175 149176 149177 149178 149179 149180 149181 149182 149183 149184 149185 149186 149187 149188 149189 149190 149191 149192 149193 149194 149195 149196 149197 149198 149199 149200 149201 149202 149203 149204 149205 149206 149207 149208 149209 149210 149211 149212 149213 149214 149215 149216 149217 149218 149219 149220 149221 149222 149223 149224 149225 149226 149227 149228 149229 149230 149231 149232 149233 149234 149235 149236 149237 149238 149239 149240 149241 149242 149243 149244 149245 149246 149247 149248 149249 149250 149251 149252 149253 149254 149255 149256 149257 149258 149259 149260 149261 149262 149263 149264 149265 149266 149267 149268 149269 149270 149271 149272 149273 149274 149275 149276 149277 149278 149279 149280 149281 149282 149283 149284 149285 149286 149287 149288 149289 149290 149291 149292 149293 149294 149295 149296 149297 149298 149299 149300 149301 149302 149303 149304 149305 149306 149307 149308 149309 149310 149311 149312 149313 149314 149315 149316 149317 149318 149319 149320 149321 149322 149323 149324 149325 149326 149327 149328 149329 149330 149331 149332 149333 149334 149335 149336 149337 149338 149339 149340 149341 149342 149343 149344 149345 149346 149347 149348 149349 149350 149351 149352 149353 149354 149355 149356 149357 149358 149359 149360 149361 149362 149363 149364 149365 149366 149367 149368 149369 149370 149371 149372 149373 149374 149375 149376 149377 149378 149379 149380 149381 149382 149383 149384 149385 149386 149387 149388 149389 149390 149391 149392 149393 149394 149395 149396 149397 149398 149399 149400 149401 149402 149403 149404 149405 149406 149407 149408 149409 149410 149411 149412 149413 149414 149415 149416 149417 149418 149419 149420 149421 149422 149423 149424 149425 149426 149427 149428 149429 149430 149431 149432 149433 149434 149435 149436 149437 149438 149439 149440 149441 149442 149443 149444 149445 149446 149447 149448 149449 149450 149451 149452 149453 149454 149455 149456 149457 149458 149459 149460 149461 149462 149463 149464 149465 149466 149467 149468 149469 149470 149471 149472 149473 149474 149475 149476 149477 149478 149479 149480 149481 149482 149483 149484 149485 149486 149487 149488 149489 149490 149491 149492 149493 149494 149495 149496 149497 149498 149499 149500 149501 149502 149503 149504 149505 149506 149507 149508 149509 149510 149511 149512 149513 149514 149515 149516 149517 149518 149519 | ** yy_reduce_ofst[] For each state, the offset into yy_action for ** shifting non-terminals after a reduce. ** yy_default[] Default action for each state. ** *********** Begin parsing tables **********************************************/ #define YY_ACTTAB_COUNT (2142) static const YYACTIONTYPE yy_action[] = { /* 0 */ 112, 109, 209, 112, 109, 209, 1160, 1, 1, 539, /* 10 */ 2, 1164, 490, 1193, 1293, 534, 289, 1196, 134, 383, /* 20 */ 1485, 1428, 1164, 1229, 1208, 1242, 1195, 289, 491, 134, /* 30 */ 373, 915, 1229, 443, 16, 16, 1242, 70, 70, 916, /* 40 */ 242, 1292, 296, 119, 120, 110, 1136, 1136, 981, 984, /* 50 */ 974, 974, 117, 117, 118, 118, 118, 118, 264, 264, /* 60 */ 190, 264, 264, 264, 264, 112, 109, 209, 362, 264, /* 70 */ 264, 531, 376, 497, 531, 1134, 531, 1501, 239, 206, /* 80 */ 338, 9, 531, 242, 219, 1203, 118, 118, 118, 118, /* 90 */ 111, 439, 112, 109, 209, 219, 116, 116, 116, 116, /* 100 */ 115, 115, 114, 114, 114, 113, 414, 115, 115, 114, /* 110 */ 114, 114, 113, 414, 418, 12, 383, 400, 1134, 114, /* 120 */ 114, 114, 113, 414, 1115, 418, 1134, 1392, 116, 116, /* 130 */ 116, 116, 115, 115, 114, 114, 114, 113, 414, 961, /* 140 */ 119, 120, 110, 1136, 1136, 981, 984, 974, 974, 117, /* 150 */ 117, 118, 118, 118, 118, 952, 534, 414, 941, 951, /* 160 */ 1481, 539, 2, 1164, 1505, 534, 160, 175, 289, 1134, /* 170 */ 134, 434, 312, 297, 1115, 1116, 1117, 1242, 70, 70, /* 180 */ 1089, 338, 1089, 118, 118, 118, 118, 42, 42, 448, /* 190 */ 951, 951, 953, 116, 116, 116, 116, 115, 115, 114, /* 200 */ 114, 114, 113, 414, 1115, 311, 264, 264, 82, 441, /* 210 */ 264, 264, 190, 383, 284, 12, 288, 525, 407, 531, /* 220 */ 96, 159, 458, 531, 371, 116, 116, 116, 116, 115, /* 230 */ 115, 114, 114, 114, 113, 414, 219, 119, 120, 110, /* 240 */ 1136, 1136, 981, 984, 974, 974, 117, 117, 118, 118, /* 250 */ 118, 118, 511, 1477, 1115, 1116, 1117, 113, 414, 534, /* 260 */ 528, 528, 528, 121, 534, 1427, 418, 116, 116, 116, /* 270 */ 116, 115, 115, 114, 114, 114, 113, 414, 1464, 351, /* 280 */ 270, 42, 42, 383, 187, 1115, 70, 70, 533, 433, /* 290 */ 116, 116, 116, 116, 115, 115, 114, 114, 114, 113, /* 300 */ 414, 534, 1339, 405, 159, 411, 410, 119, 120, 110, /* 310 */ 1136, 1136, 981, 984, 974, 974, 117, 117, 118, 118, /* 320 */ 118, 118, 285, 42, 42, 349, 411, 410, 514, 479, /* 330 */ 1458, 79, 1084, 6, 1140, 1115, 1116, 1117, 480, 1142, /* 340 */ 501, 1115, 1084, 123, 238, 1084, 136, 1141, 1234, 1234, /* 350 */ 1143, 383, 1143, 1115, 167, 426, 80, 447, 512, 1451, /* 360 */ 116, 116, 116, 116, 115, 115, 114, 114, 114, 113, /* 370 */ 414, 1143, 1466, 1143, 350, 119, 120, 110, 1136, 1136, /* 380 */ 981, 984, 974, 974, 117, 117, 118, 118, 118, 118, /* 390 */ 402, 1115, 1116, 1117, 500, 534, 250, 267, 336, 474, /* 400 */ 331, 473, 236, 1115, 1116, 1117, 231, 1115, 329, 471, /* 410 */ 468, 467, 509, 1458, 1464, 505, 6, 70, 70, 466, /* 420 */ 181, 380, 379, 534, 971, 971, 982, 985, 116, 116, /* 430 */ 116, 116, 115, 115, 114, 114, 114, 113, 414, 1115, /* 440 */ 412, 412, 412, 496, 1115, 69, 69, 235, 383, 288, /* 450 */ 525, 273, 326, 516, 337, 458, 1084, 1115, 1116, 1117, /* 460 */ 1232, 1232, 492, 160, 508, 441, 1084, 1067, 1531, 1084, /* 470 */ 207, 1531, 119, 120, 110, 1136, 1136, 981, 984, 974, /* 480 */ 974, 117, 117, 118, 118, 118, 118, 881, 534, 1115, /* 490 */ 1116, 1117, 975, 534, 1115, 1116, 1117, 534, 421, 534, /* 500 */ 141, 534, 176, 356, 517, 1119, 32, 511, 482, 388, /* 510 */ 70, 70, 818, 288, 525, 70, 70, 441, 499, 50, /* 520 */ 50, 70, 70, 70, 70, 116, 116, 116, 116, 115, /* 530 */ 115, 114, 114, 114, 113, 414, 274, 264, 264, 1115, /* 540 */ 1065, 264, 264, 1115, 355, 383, 409, 961, 1439, 822, /* 550 */ 531, 516, 190, 419, 531, 483, 1119, 516, 337, 516, /* 560 */ 518, 1115, 818, 952, 382, 458, 515, 951, 481, 119, /* 570 */ 120, 110, 1136, 1136, 981, 984, 974, 974, 117, 117, /* 580 */ 118, 118, 118, 118, 1338, 278, 1045, 278, 275, 1115, /* 590 */ 1116, 1117, 259, 1115, 1116, 1117, 534, 5, 951, 951, /* 600 */ 953, 1046, 231, 3, 143, 471, 468, 467, 1391, 463, /* 610 */ 1115, 1115, 1116, 1117, 1452, 466, 1047, 836, 70, 70, /* 620 */ 480, 534, 116, 116, 116, 116, 115, 115, 114, 114, /* 630 */ 114, 113, 414, 95, 1115, 287, 235, 856, 902, 420, /* 640 */ 1115, 534, 383, 13, 13, 381, 815, 857, 472, 112, /* 650 */ 109, 209, 1115, 337, 413, 309, 837, 394, 1436, 534, /* 660 */ 1115, 1116, 1117, 54, 54, 291, 119, 120, 110, 1136, /* 670 */ 1136, 981, 984, 974, 974, 117, 117, 118, 118, 118, /* 680 */ 118, 13, 13, 1084, 1115, 1116, 1117, 901, 264, 264, /* 690 */ 1115, 1116, 1117, 1084, 292, 399, 1084, 800, 388, 140, /* 700 */ 295, 531, 1115, 1116, 1117, 403, 447, 532, 534, 870, /* 710 */ 870, 534, 1240, 534, 329, 534, 1185, 389, 534, 116, /* 720 */ 116, 116, 116, 115, 115, 114, 114, 114, 113, 414, /* 730 */ 13, 13, 1024, 13, 13, 13, 13, 13, 13, 383, /* 740 */ 13, 13, 424, 1100, 401, 264, 264, 277, 160, 184, /* 750 */ 1182, 185, 1533, 369, 513, 484, 432, 487, 531, 424, /* 760 */ 423, 1397, 941, 119, 120, 110, 1136, 1136, 981, 984, /* 770 */ 974, 974, 117, 117, 118, 118, 118, 118, 1397, 1399, /* 780 */ 425, 519, 392, 264, 264, 1029, 1029, 455, 264, 264, /* 790 */ 264, 264, 1004, 304, 261, 1278, 531, 900, 288, 525, /* 800 */ 310, 531, 493, 531, 1067, 1532, 458, 387, 1532, 311, /* 810 */ 429, 299, 534, 107, 264, 264, 116, 116, 116, 116, /* 820 */ 115, 115, 114, 114, 114, 113, 414, 531, 424, 1384, /* 830 */ 507, 258, 258, 1246, 55, 55, 383, 1277, 265, 265, /* 840 */ 962, 324, 434, 312, 531, 531, 506, 1397, 1026, 1241, /* 850 */ 298, 531, 1026, 445, 301, 1095, 303, 534, 368, 1156, /* 860 */ 119, 120, 110, 1136, 1136, 981, 984, 974, 974, 117, /* 870 */ 117, 118, 118, 118, 118, 1045, 534, 1065, 534, 15, /* 880 */ 15, 1084, 208, 1324, 453, 452, 534, 1324, 534, 449, /* 890 */ 1046, 1084, 494, 458, 1084, 234, 233, 232, 44, 44, /* 900 */ 56, 56, 319, 1095, 322, 1047, 534, 900, 57, 57, /* 910 */ 58, 58, 534, 116, 116, 116, 116, 115, 115, 114, /* 920 */ 114, 114, 113, 414, 534, 514, 522, 534, 59, 59, /* 930 */ 302, 1157, 534, 383, 60, 60, 1237, 946, 788, 789, /* 940 */ 790, 1459, 1456, 446, 6, 6, 61, 61, 1212, 45, /* 950 */ 45, 534, 396, 383, 46, 46, 397, 119, 120, 110, /* 960 */ 1136, 1136, 981, 984, 974, 974, 117, 117, 118, 118, /* 970 */ 118, 118, 428, 48, 48, 534, 392, 119, 120, 110, /* 980 */ 1136, 1136, 981, 984, 974, 974, 117, 117, 118, 118, /* 990 */ 118, 118, 1324, 368, 1066, 447, 825, 49, 49, 534, /* 1000 */ 458, 357, 534, 353, 534, 138, 534, 337, 1478, 478, /* 1010 */ 116, 116, 116, 116, 115, 115, 114, 114, 114, 113, /* 1020 */ 414, 62, 62, 392, 63, 63, 64, 64, 14, 14, /* 1030 */ 116, 116, 116, 116, 115, 115, 114, 114, 114, 113, /* 1040 */ 414, 534, 810, 317, 271, 534, 1457, 825, 534, 6, /* 1050 */ 534, 1324, 534, 142, 534, 1442, 534, 212, 534, 1324, /* 1060 */ 534, 398, 305, 65, 65, 534, 1157, 125, 125, 476, /* 1070 */ 66, 66, 51, 51, 67, 67, 68, 68, 52, 52, /* 1080 */ 147, 147, 148, 148, 534, 98, 534, 75, 75, 276, /* 1090 */ 534, 272, 534, 810, 534, 876, 534, 527, 389, 534, /* 1100 */ 875, 534, 1151, 202, 534, 383, 53, 53, 71, 71, /* 1110 */ 288, 525, 126, 126, 72, 72, 127, 127, 128, 128, /* 1120 */ 454, 124, 124, 146, 146, 383, 145, 145, 408, 119, /* 1130 */ 120, 110, 1136, 1136, 981, 984, 974, 974, 117, 117, /* 1140 */ 118, 118, 118, 118, 534, 900, 534, 95, 534, 119, /* 1150 */ 120, 110, 1136, 1136, 981, 984, 974, 974, 117, 117, /* 1160 */ 118, 118, 118, 118, 390, 161, 132, 132, 131, 131, /* 1170 */ 129, 129, 534, 915, 534, 1455, 534, 1454, 6, 1416, /* 1180 */ 6, 916, 116, 116, 116, 116, 115, 115, 114, 114, /* 1190 */ 114, 113, 414, 1415, 130, 130, 74, 74, 76, 76, /* 1200 */ 534, 30, 116, 116, 116, 116, 115, 115, 114, 114, /* 1210 */ 114, 113, 414, 534, 263, 206, 534, 1133, 1504, 93, /* 1220 */ 876, 845, 73, 73, 102, 875, 100, 139, 17, 38, /* 1230 */ 208, 1062, 31, 450, 370, 43, 43, 101, 47, 47, /* 1240 */ 827, 216, 436, 308, 943, 440, 95, 241, 241, 442, /* 1250 */ 313, 464, 241, 95, 237, 900, 327, 383, 266, 95, /* 1260 */ 835, 834, 193, 335, 938, 314, 1011, 435, 842, 843, /* 1270 */ 955, 1007, 909, 334, 237, 241, 873, 383, 1023, 107, /* 1280 */ 1023, 119, 120, 110, 1136, 1136, 981, 984, 974, 974, /* 1290 */ 117, 117, 118, 118, 118, 118, 1022, 808, 1022, 1274, /* 1300 */ 137, 119, 108, 110, 1136, 1136, 981, 984, 974, 974, /* 1310 */ 117, 117, 118, 118, 118, 118, 874, 1011, 318, 107, /* 1320 */ 321, 955, 323, 325, 1225, 1211, 197, 1210, 1209, 330, /* 1330 */ 339, 1265, 340, 283, 116, 116, 116, 116, 115, 115, /* 1340 */ 114, 114, 114, 113, 414, 1286, 1323, 1261, 1471, 1272, /* 1350 */ 520, 218, 521, 1329, 116, 116, 116, 116, 115, 115, /* 1360 */ 114, 114, 114, 113, 414, 1192, 1184, 1173, 1172, 1174, /* 1370 */ 1494, 1488, 459, 256, 383, 1258, 342, 199, 367, 344, /* 1380 */ 211, 195, 307, 444, 11, 346, 469, 333, 1308, 1316, /* 1390 */ 375, 427, 203, 360, 383, 1388, 188, 1387, 189, 120, /* 1400 */ 110, 1136, 1136, 981, 984, 974, 974, 117, 117, 118, /* 1410 */ 118, 118, 118, 1208, 1151, 300, 348, 1491, 245, 1148, /* 1420 */ 110, 1136, 1136, 981, 984, 974, 974, 117, 117, 118, /* 1430 */ 118, 118, 118, 198, 1435, 1433, 524, 78, 391, 163, /* 1440 */ 82, 1393, 438, 173, 81, 105, 526, 1313, 4, 35, /* 1450 */ 157, 116, 116, 116, 116, 115, 115, 114, 114, 114, /* 1460 */ 113, 414, 529, 165, 93, 430, 1305, 168, 169, 431, /* 1470 */ 462, 116, 116, 116, 116, 115, 115, 114, 114, 114, /* 1480 */ 113, 414, 170, 171, 221, 415, 372, 437, 1319, 177, /* 1490 */ 374, 36, 451, 225, 1382, 87, 457, 523, 257, 1404, /* 1500 */ 316, 105, 526, 227, 4, 182, 460, 160, 320, 228, /* 1510 */ 377, 1175, 475, 229, 1228, 404, 1227, 1226, 529, 827, /* 1520 */ 961, 1219, 378, 1200, 1199, 406, 103, 103, 1218, 332, /* 1530 */ 8, 281, 1198, 104, 1503, 415, 536, 535, 486, 282, /* 1540 */ 951, 415, 489, 495, 92, 244, 1269, 341, 243, 122, /* 1550 */ 1270, 343, 514, 523, 1268, 1462, 10, 288, 525, 345, /* 1560 */ 1461, 354, 99, 352, 503, 94, 1267, 347, 1251, 502, /* 1570 */ 498, 951, 951, 953, 954, 27, 961, 1250, 194, 358, /* 1580 */ 251, 359, 103, 103, 1181, 34, 537, 1110, 252, 104, /* 1590 */ 254, 415, 536, 535, 255, 1368, 951, 1420, 286, 538, /* 1600 */ 1170, 1165, 1421, 135, 1419, 1418, 149, 150, 279, 784, /* 1610 */ 416, 196, 151, 290, 210, 200, 77, 385, 269, 386, /* 1620 */ 133, 162, 935, 1021, 201, 1019, 153, 951, 951, 953, /* 1630 */ 954, 27, 1480, 1104, 417, 164, 217, 268, 859, 166, /* 1640 */ 306, 1035, 366, 366, 365, 253, 363, 220, 172, 797, /* 1650 */ 939, 155, 105, 526, 393, 4, 395, 174, 156, 83, /* 1660 */ 1038, 84, 213, 85, 294, 222, 86, 223, 1034, 529, /* 1670 */ 144, 18, 293, 224, 315, 456, 241, 1027, 1145, 178, /* 1680 */ 226, 179, 37, 799, 334, 461, 230, 465, 470, 838, /* 1690 */ 180, 88, 415, 19, 280, 328, 20, 89, 90, 158, /* 1700 */ 191, 477, 215, 1097, 523, 204, 192, 987, 91, 1070, /* 1710 */ 152, 39, 485, 154, 1071, 503, 40, 488, 205, 260, /* 1720 */ 504, 262, 105, 526, 214, 4, 908, 961, 183, 240, /* 1730 */ 903, 107, 1086, 103, 103, 21, 22, 1088, 23, 529, /* 1740 */ 104, 24, 415, 536, 535, 1090, 1093, 951, 1094, 25, /* 1750 */ 1074, 33, 7, 26, 510, 1002, 247, 186, 384, 95, /* 1760 */ 988, 986, 415, 288, 525, 990, 1044, 246, 1043, 991, /* 1770 */ 28, 41, 530, 956, 523, 809, 106, 29, 951, 951, /* 1780 */ 953, 954, 27, 869, 361, 503, 422, 248, 364, 1105, /* 1790 */ 502, 249, 1161, 1496, 1495, 1161, 1161, 961, 1161, 1161, /* 1800 */ 1161, 1161, 1161, 103, 103, 1161, 1161, 1161, 1161, 1161, /* 1810 */ 104, 1161, 415, 536, 535, 1104, 417, 951, 1161, 268, /* 1820 */ 1161, 1161, 1161, 1161, 366, 366, 365, 253, 363, 1161, /* 1830 */ 1161, 797, 1161, 1161, 1161, 1161, 105, 526, 1161, 4, /* 1840 */ 1161, 1161, 1161, 1161, 213, 1161, 294, 1161, 951, 951, /* 1850 */ 953, 954, 27, 529, 293, 1161, 1161, 1161, 1161, 1161, /* 1860 */ 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, /* 1870 */ 1161, 1161, 1161, 1161, 1161, 1161, 415, 1161, 1161, 1161, /* 1880 */ 1161, 1161, 1161, 1161, 215, 1161, 1161, 1161, 523, 1161, /* 1890 */ 1161, 1161, 152, 1161, 1161, 154, 105, 526, 1161, 4, /* 1900 */ 1161, 1161, 1161, 1161, 1161, 1161, 214, 1161, 1161, 1161, /* 1910 */ 1161, 961, 1161, 529, 1161, 1161, 1161, 103, 103, 880, /* 1920 */ 1161, 1161, 1161, 1161, 104, 1161, 415, 536, 535, 1161, /* 1930 */ 1161, 951, 1161, 1161, 1161, 1161, 415, 1161, 1161, 1161, /* 1940 */ 384, 1161, 1161, 1161, 1161, 288, 525, 1161, 523, 1161, /* 1950 */ 1161, 1161, 1161, 1161, 1161, 1161, 97, 526, 1161, 4, /* 1960 */ 1161, 1161, 951, 951, 953, 954, 27, 1161, 422, 1161, /* 1970 */ 1161, 961, 1161, 529, 1161, 1161, 1161, 103, 103, 1161, /* 1980 */ 1161, 1161, 1161, 1161, 104, 1161, 415, 536, 535, 1161, /* 1990 */ 1161, 951, 268, 1161, 1161, 1161, 415, 366, 366, 365, /* 2000 */ 253, 363, 1161, 1161, 797, 1161, 1161, 1161, 523, 1161, /* 2010 */ 1161, 1161, 1161, 1161, 1161, 1161, 1161, 213, 1161, 294, /* 2020 */ 1161, 1161, 951, 951, 953, 954, 27, 293, 1161, 1161, /* 2030 */ 1161, 961, 1161, 1161, 1161, 1161, 1161, 103, 103, 1161, /* 2040 */ 1161, 1161, 1161, 1161, 104, 1161, 415, 536, 535, 1161, /* 2050 */ 1161, 951, 1161, 1161, 1161, 1161, 1161, 215, 1161, 1161, /* 2060 */ 1161, 1161, 1161, 1161, 1161, 152, 1161, 1161, 154, 1161, /* 2070 */ 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 214, /* 2080 */ 1161, 1161, 951, 951, 953, 954, 27, 1161, 1161, 1161, /* 2090 */ 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, /* 2100 */ 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, /* 2110 */ 1161, 1161, 1161, 384, 1161, 1161, 1161, 1161, 288, 525, /* 2120 */ 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, /* 2130 */ 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, /* 2140 */ 1161, 422, }; static const YYCODETYPE yy_lookahead[] = { /* 0 */ 260, 261, 262, 260, 261, 262, 176, 177, 178, 179, /* 10 */ 180, 181, 184, 206, 209, 184, 186, 206, 188, 19, /* 20 */ 179, 281, 181, 213, 214, 195, 206, 186, 195, 188, /* 30 */ 195, 31, 222, 184, 206, 207, 195, 206, 207, 39, /* 40 */ 24, 209, 184, 43, 44, 45, 46, 47, 48, 49, /* 50 */ 50, 51, 52, 53, 54, 55, 56, 57, 228, 229, /* 60 */ 184, 228, 229, 228, 229, 260, 261, 262, 192, 228, /* 70 */ 229, 241, 196, 242, 241, 59, 241, 205, 245, 246, /* 80 */ 184, 22, 241, 24, 254, 213, 54, 55, 56, 57, /* 90 */ 58, 256, 260, 261, 262, 254, 96, 97, 98, 99, /* 100 */ 100, 101, 102, 103, 104, 105, 106, 100, 101, 102, /* 110 */ 103, 104, 105, 106, 284, 203, 19, 221, 59, 102, /* 120 */ 103, 104, 105, 106, 59, 284, 110, 269, 96, 97, /* 130 */ 98, 99, 100, 101, 102, 103, 104, 105, 106, 94, /* 140 */ 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, /* 150 */ 53, 54, 55, 56, 57, 110, 184, 106, 73, 114, /* 160 */ 178, 179, 180, 181, 219, 184, 81, 22, 186, 110, /* 170 */ 188, 121, 122, 195, 109, 110, 111, 195, 206, 207, /* 180 */ 83, 184, 85, 54, 55, 56, 57, 206, 207, 277, /* 190 */ 145, 146, 147, 96, 97, 98, 99, 100, 101, 102, /* 200 */ 103, 104, 105, 106, 59, 120, 228, 229, 143, 184, /* 210 */ 228, 229, 184, 19, 242, 203, 131, 132, 221, 241, /* 220 */ 26, 184, 184, 241, 196, 96, 97, 98, 99, 100, /* 230 */ 101, 102, 103, 104, 105, 106, 254, 43, 44, 45, /* 240 */ 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, /* 250 */ 56, 57, 184, 184, 109, 110, 111, 105, 106, 184, /* 260 */ 200, 201, 202, 69, 184, 227, 284, 96, 97, 98, /* 270 */ 99, 100, 101, 102, 103, 104, 105, 106, 297, 298, /* 280 */ 255, 206, 207, 19, 272, 59, 206, 207, 184, 277, /* 290 */ 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, /* 300 */ 106, 184, 259, 19, 184, 100, 101, 43, 44, 45, /* 310 */ 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, /* 320 */ 56, 57, 242, 206, 207, 184, 100, 101, 138, 292, /* 330 */ 293, 67, 76, 296, 108, 109, 110, 111, 295, 113, /* 340 */ 84, 59, 86, 22, 26, 89, 156, 121, 224, 225, /* 350 */ 145, 19, 147, 59, 72, 256, 24, 184, 290, 291, /* 360 */ 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, /* 370 */ 106, 145, 297, 147, 299, 43, 44, 45, 46, 47, /* 380 */ 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, /* 390 */ 106, 109, 110, 111, 138, 184, 112, 113, 114, 115, /* 400 */ 116, 117, 118, 109, 110, 111, 112, 59, 124, 115, /* 410 */ 116, 117, 292, 293, 297, 298, 296, 206, 207, 125, /* 420 */ 72, 100, 101, 184, 46, 47, 48, 49, 96, 97, /* 430 */ 98, 99, 100, 101, 102, 103, 104, 105, 106, 59, /* 440 */ 200, 201, 202, 184, 59, 206, 207, 46, 19, 131, /* 450 */ 132, 278, 23, 242, 184, 184, 76, 109, 110, 111, /* 460 */ 224, 225, 251, 81, 84, 184, 86, 22, 23, 89, /* 470 */ 184, 26, 43, 44, 45, 46, 47, 48, 49, 50, /* 480 */ 51, 52, 53, 54, 55, 56, 57, 102, 184, 109, /* 490 */ 110, 111, 114, 184, 109, 110, 111, 184, 227, 184, /* 500 */ 230, 184, 22, 264, 195, 59, 22, 184, 195, 108, /* 510 */ 206, 207, 59, 131, 132, 206, 207, 184, 138, 206, /* 520 */ 207, 206, 207, 206, 207, 96, 97, 98, 99, 100, /* 530 */ 101, 102, 103, 104, 105, 106, 255, 228, 229, 59, /* 540 */ 95, 228, 229, 59, 184, 19, 242, 94, 184, 23, /* 550 */ 241, 242, 184, 282, 241, 242, 110, 242, 184, 242, /* 560 */ 251, 59, 109, 110, 196, 184, 251, 114, 251, 43, /* 570 */ 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, /* 580 */ 54, 55, 56, 57, 259, 217, 12, 219, 255, 109, /* 590 */ 110, 111, 203, 109, 110, 111, 184, 22, 145, 146, /* 600 */ 147, 27, 112, 22, 230, 115, 116, 117, 227, 19, /* 610 */ 59, 109, 110, 111, 291, 125, 42, 35, 206, 207, /* 620 */ 295, 184, 96, 97, 98, 99, 100, 101, 102, 103, /* 630 */ 104, 105, 106, 26, 59, 233, 46, 63, 136, 184, /* 640 */ 59, 184, 19, 206, 207, 243, 23, 73, 66, 260, /* 650 */ 261, 262, 59, 184, 242, 195, 74, 220, 184, 184, /* 660 */ 109, 110, 111, 206, 207, 184, 43, 44, 45, 46, /* 670 */ 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, /* 680 */ 57, 206, 207, 76, 109, 110, 111, 136, 228, 229, /* 690 */ 109, 110, 111, 86, 184, 220, 89, 21, 108, 230, /* 700 */ 184, 241, 109, 110, 111, 123, 184, 127, 184, 129, /* 710 */ 130, 184, 195, 184, 124, 184, 198, 199, 184, 96, /* 720 */ 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, /* 730 */ 206, 207, 11, 206, 207, 206, 207, 206, 207, 19, /* 740 */ 206, 207, 184, 23, 220, 228, 229, 220, 81, 220, /* 750 */ 195, 220, 287, 288, 220, 195, 80, 195, 241, 201, /* 760 */ 202, 184, 73, 43, 44, 45, 46, 47, 48, 49, /* 770 */ 50, 51, 52, 53, 54, 55, 56, 57, 201, 202, /* 780 */ 113, 195, 184, 228, 229, 120, 121, 122, 228, 229, /* 790 */ 228, 229, 116, 16, 23, 184, 241, 26, 131, 132, /* 800 */ 278, 241, 19, 241, 22, 23, 184, 189, 26, 120, /* 810 */ 121, 122, 184, 26, 228, 229, 96, 97, 98, 99, /* 820 */ 100, 101, 102, 103, 104, 105, 106, 241, 270, 153, /* 830 */ 66, 228, 229, 229, 206, 207, 19, 184, 228, 229, /* 840 */ 23, 16, 121, 122, 241, 241, 82, 270, 29, 227, /* 850 */ 252, 241, 33, 19, 77, 91, 79, 184, 22, 23, /* 860 */ 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, /* 870 */ 53, 54, 55, 56, 57, 12, 184, 95, 184, 206, /* 880 */ 207, 76, 111, 184, 65, 267, 184, 184, 184, 271, /* 890 */ 27, 86, 109, 184, 89, 120, 121, 122, 206, 207, /* 900 */ 206, 207, 77, 139, 79, 42, 184, 136, 206, 207, /* 910 */ 206, 207, 184, 96, 97, 98, 99, 100, 101, 102, /* 920 */ 103, 104, 105, 106, 184, 138, 63, 184, 206, 207, /* 930 */ 153, 95, 184, 19, 206, 207, 227, 23, 7, 8, /* 940 */ 9, 293, 293, 109, 296, 296, 206, 207, 215, 206, /* 950 */ 207, 184, 253, 19, 206, 207, 253, 43, 44, 45, /* 960 */ 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, /* 970 */ 56, 57, 184, 206, 207, 184, 184, 43, 44, 45, /* 980 */ 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, /* 990 */ 56, 57, 184, 22, 23, 184, 59, 206, 207, 184, /* 1000 */ 184, 238, 184, 240, 184, 22, 184, 184, 157, 158, /* 1010 */ 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, /* 1020 */ 106, 206, 207, 184, 206, 207, 206, 207, 206, 207, /* 1030 */ 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, /* 1040 */ 106, 184, 59, 227, 252, 184, 293, 110, 184, 296, /* 1050 */ 184, 184, 184, 230, 184, 184, 184, 15, 184, 184, /* 1060 */ 184, 253, 184, 206, 207, 184, 95, 206, 207, 102, /* 1070 */ 206, 207, 206, 207, 206, 207, 206, 207, 206, 207, /* 1080 */ 206, 207, 206, 207, 184, 151, 184, 206, 207, 278, /* 1090 */ 184, 252, 184, 110, 184, 128, 184, 198, 199, 184, /* 1100 */ 133, 184, 60, 26, 184, 19, 206, 207, 206, 207, /* 1110 */ 131, 132, 206, 207, 206, 207, 206, 207, 206, 207, /* 1120 */ 253, 206, 207, 206, 207, 19, 206, 207, 253, 43, /* 1130 */ 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, /* 1140 */ 54, 55, 56, 57, 184, 26, 184, 26, 184, 43, /* 1150 */ 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, /* 1160 */ 54, 55, 56, 57, 285, 286, 206, 207, 206, 207, /* 1170 */ 206, 207, 184, 31, 184, 293, 184, 293, 296, 184, /* 1180 */ 296, 39, 96, 97, 98, 99, 100, 101, 102, 103, /* 1190 */ 104, 105, 106, 184, 206, 207, 206, 207, 206, 207, /* 1200 */ 184, 22, 96, 97, 98, 99, 100, 101, 102, 103, /* 1210 */ 104, 105, 106, 184, 245, 246, 184, 26, 23, 142, /* 1220 */ 128, 26, 206, 207, 150, 133, 152, 22, 22, 24, /* 1230 */ 111, 23, 53, 184, 26, 206, 207, 151, 206, 207, /* 1240 */ 119, 24, 122, 23, 23, 23, 26, 26, 26, 23, /* 1250 */ 23, 23, 26, 26, 26, 136, 23, 19, 22, 26, /* 1260 */ 113, 114, 24, 114, 144, 184, 59, 61, 7, 8, /* 1270 */ 59, 23, 23, 124, 26, 26, 23, 19, 145, 26, /* 1280 */ 147, 43, 44, 45, 46, 47, 48, 49, 50, 51, /* 1290 */ 52, 53, 54, 55, 56, 57, 145, 23, 147, 184, /* 1300 */ 26, 43, 44, 45, 46, 47, 48, 49, 50, 51, /* 1310 */ 52, 53, 54, 55, 56, 57, 23, 110, 184, 26, /* 1320 */ 184, 110, 184, 184, 184, 215, 135, 215, 184, 184, /* 1330 */ 184, 247, 184, 244, 96, 97, 98, 99, 100, 101, /* 1340 */ 102, 103, 104, 105, 106, 184, 184, 184, 301, 184, /* 1350 */ 184, 134, 225, 184, 96, 97, 98, 99, 100, 101, /* 1360 */ 102, 103, 104, 105, 106, 184, 184, 184, 184, 184, /* 1370 */ 134, 184, 274, 273, 19, 244, 244, 204, 182, 244, /* 1380 */ 283, 231, 279, 279, 232, 244, 210, 209, 235, 235, /* 1390 */ 235, 248, 218, 234, 19, 209, 238, 209, 238, 44, /* 1400 */ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, /* 1410 */ 55, 56, 57, 214, 60, 248, 248, 187, 134, 38, /* 1420 */ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, /* 1430 */ 55, 56, 57, 232, 191, 191, 266, 280, 191, 283, /* 1440 */ 143, 269, 108, 22, 280, 19, 20, 258, 22, 257, /* 1450 */ 43, 96, 97, 98, 99, 100, 101, 102, 103, 104, /* 1460 */ 105, 106, 36, 223, 142, 18, 235, 226, 226, 191, /* 1470 */ 18, 96, 97, 98, 99, 100, 101, 102, 103, 104, /* 1480 */ 105, 106, 226, 226, 190, 59, 235, 235, 223, 223, /* 1490 */ 258, 257, 191, 190, 235, 150, 62, 71, 191, 276, /* 1500 */ 275, 19, 20, 190, 22, 22, 211, 81, 191, 190, /* 1510 */ 211, 191, 108, 190, 208, 64, 208, 208, 36, 119, /* 1520 */ 94, 216, 211, 208, 210, 106, 100, 101, 216, 208, /* 1530 */ 48, 268, 208, 107, 208, 109, 110, 111, 211, 268, /* 1540 */ 114, 59, 211, 137, 108, 88, 250, 249, 191, 141, /* 1550 */ 250, 249, 138, 71, 250, 300, 22, 131, 132, 249, /* 1560 */ 300, 191, 150, 238, 82, 140, 250, 249, 239, 87, /* 1570 */ 139, 145, 146, 147, 148, 149, 94, 239, 237, 236, /* 1580 */ 25, 235, 100, 101, 194, 26, 193, 13, 185, 107, /* 1590 */ 185, 109, 110, 111, 6, 263, 114, 203, 265, 183, /* 1600 */ 183, 183, 203, 212, 203, 203, 197, 197, 212, 4, /* 1610 */ 3, 22, 197, 155, 15, 204, 203, 289, 93, 289, /* 1620 */ 16, 286, 132, 23, 204, 23, 123, 145, 146, 147, /* 1630 */ 148, 149, 0, 1, 2, 143, 24, 5, 20, 135, /* 1640 */ 16, 1, 10, 11, 12, 13, 14, 137, 135, 17, /* 1650 */ 144, 123, 19, 20, 61, 22, 37, 143, 123, 53, /* 1660 */ 109, 53, 30, 53, 32, 34, 53, 134, 1, 36, /* 1670 */ 5, 22, 40, 108, 153, 41, 26, 68, 75, 68, /* 1680 */ 134, 108, 24, 20, 124, 19, 118, 67, 67, 28, /* 1690 */ 22, 22, 59, 22, 67, 23, 22, 22, 142, 37, /* 1700 */ 23, 22, 70, 23, 71, 157, 23, 23, 26, 23, /* 1710 */ 78, 22, 24, 81, 23, 82, 22, 24, 134, 23, /* 1720 */ 87, 23, 19, 20, 92, 22, 109, 94, 22, 34, /* 1730 */ 136, 26, 85, 100, 101, 34, 34, 83, 34, 36, /* 1740 */ 107, 34, 109, 110, 111, 75, 90, 114, 75, 34, /* 1750 */ 23, 22, 44, 34, 24, 23, 22, 26, 126, 26, /* 1760 */ 23, 23, 59, 131, 132, 23, 23, 26, 23, 11, /* 1770 */ 22, 22, 26, 23, 71, 23, 22, 22, 145, 146, /* 1780 */ 147, 148, 149, 128, 23, 82, 154, 134, 15, 1, /* 1790 */ 87, 134, 302, 134, 134, 302, 302, 94, 302, 302, /* 1800 */ 302, 302, 302, 100, 101, 302, 302, 302, 302, 302, /* 1810 */ 107, 302, 109, 110, 111, 1, 2, 114, 302, 5, /* 1820 */ 302, 302, 302, 302, 10, 11, 12, 13, 14, 302, /* 1830 */ 302, 17, 302, 302, 302, 302, 19, 20, 302, 22, /* 1840 */ 302, 302, 302, 302, 30, 302, 32, 302, 145, 146, /* 1850 */ 147, 148, 149, 36, 40, 302, 302, 302, 302, 302, /* 1860 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, 302, /* 1870 */ 302, 302, 302, 302, 302, 302, 59, 302, 302, 302, /* 1880 */ 302, 302, 302, 302, 70, 302, 302, 302, 71, 302, /* 1890 */ 302, 302, 78, 302, 302, 81, 19, 20, 302, 22, /* 1900 */ 302, 302, 302, 302, 302, 302, 92, 302, 302, 302, /* 1910 */ 302, 94, 302, 36, 302, 302, 302, 100, 101, 102, /* 1920 */ 302, 302, 302, 302, 107, 302, 109, 110, 111, 302, /* 1930 */ 302, 114, 302, 302, 302, 302, 59, 302, 302, 302, /* 1940 */ 126, 302, 302, 302, 302, 131, 132, 302, 71, 302, /* 1950 */ 302, 302, 302, 302, 302, 302, 19, 20, 302, 22, /* 1960 */ 302, 302, 145, 146, 147, 148, 149, 302, 154, 302, /* 1970 */ 302, 94, 302, 36, 302, 302, 302, 100, 101, 302, /* 1980 */ 302, 302, 302, 302, 107, 302, 109, 110, 111, 302, /* 1990 */ 302, 114, 5, 302, 302, 302, 59, 10, 11, 12, /* 2000 */ 13, 14, 302, 302, 17, 302, 302, 302, 71, 302, /* 2010 */ 302, 302, 302, 302, 302, 302, 302, 30, 302, 32, /* 2020 */ 302, 302, 145, 146, 147, 148, 149, 40, 302, 302, /* 2030 */ 302, 94, 302, 302, 302, 302, 302, 100, 101, 302, /* 2040 */ 302, 302, 302, 302, 107, 302, 109, 110, 111, 302, /* 2050 */ 302, 114, 302, 302, 302, 302, 302, 70, 302, 302, /* 2060 */ 302, 302, 302, 302, 302, 78, 302, 302, 81, 302, /* 2070 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, 92, /* 2080 */ 302, 302, 145, 146, 147, 148, 149, 302, 302, 302, /* 2090 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, 302, /* 2100 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, 302, /* 2110 */ 302, 302, 302, 126, 302, 302, 302, 302, 131, 132, /* 2120 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, 302, /* 2130 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, 302, /* 2140 */ 302, 154, 302, 302, 302, 302, 302, 302, 302, 302, /* 2150 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, 302, /* 2160 */ 302, 302, 302, 302, 302, 302, 302, 302, 302, }; #define YY_SHIFT_COUNT (539) #define YY_SHIFT_MIN (0) #define YY_SHIFT_MAX (1987) static const unsigned short int yy_shift_ofst[] = { /* 0 */ 1814, 1632, 1987, 1426, 1426, 382, 1482, 1633, 1703, 1877, /* 10 */ 1877, 1877, 85, 0, 0, 264, 1106, 1877, 1877, 1877, /* 20 */ 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, /* 30 */ 226, 226, 380, 380, 294, 667, 382, 382, 382, 382, /* 40 */ 382, 382, 97, 194, 332, 429, 526, 623, 720, 817, /* 50 */ 914, 934, 1086, 1238, 1106, 1106, 1106, 1106, 1106, 1106, /* 60 */ 1106, 1106, 1106, 1106, 1106, 1106, 1106, 1106, 1106, 1106, /* 70 */ 1106, 1106, 1258, 1106, 1355, 1375, 1375, 1817, 1877, 1877, /* 80 */ 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, /* 90 */ 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, /* 100 */ 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, /* 110 */ 1937, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, 1877, /* 120 */ 1877, 1877, 1877, 1877, 32, 129, 129, 129, 129, 129, /* 130 */ 171, 7, 17, 593, 676, 590, 593, 205, 205, 593, /* 140 */ 318, 318, 318, 318, 50, 152, 51, 2142, 2142, 284, /* 150 */ 284, 284, 65, 145, 282, 145, 145, 574, 574, 256, /* 160 */ 348, 445, 782, 593, 593, 593, 593, 593, 593, 593, /* 170 */ 593, 593, 593, 593, 593, 593, 593, 593, 593, 593, /* 180 */ 593, 593, 593, 593, 607, 607, 593, 721, 805, 805, /* 190 */ 446, 851, 851, 446, 190, 979, 2142, 2142, 2142, 453, /* 200 */ 45, 45, 480, 490, 484, 385, 575, 502, 551, 581, /* 210 */ 593, 593, 593, 593, 593, 593, 593, 593, 593, 689, /* 220 */ 593, 593, 593, 593, 593, 593, 593, 593, 593, 593, /* 230 */ 593, 593, 582, 582, 582, 593, 593, 593, 593, 771, /* 240 */ 593, 593, 593, 59, 764, 593, 593, 863, 593, 593, /* 250 */ 593, 593, 593, 593, 593, 593, 665, 819, 580, 16, /* 260 */ 16, 16, 16, 1119, 580, 580, 967, 321, 931, 1042, /* 270 */ 1077, 783, 783, 834, 1077, 1077, 834, 1121, 1195, 401, /* 280 */ 1142, 1142, 1142, 783, 787, 787, 1074, 1191, 1092, 1205, /* 290 */ 1354, 1284, 1284, 1381, 1381, 1284, 1297, 1334, 1421, 1407, /* 300 */ 1322, 1447, 1447, 1447, 1447, 1284, 1452, 1322, 1322, 1334, /* 310 */ 1421, 1407, 1407, 1322, 1284, 1452, 1345, 1434, 1284, 1452, /* 320 */ 1483, 1284, 1452, 1284, 1452, 1483, 1404, 1404, 1404, 1451, /* 330 */ 1483, 1404, 1400, 1404, 1451, 1404, 1404, 1483, 1419, 1419, /* 340 */ 1483, 1406, 1436, 1406, 1436, 1406, 1436, 1406, 1436, 1284, /* 350 */ 1457, 1457, 1408, 1414, 1534, 1284, 1412, 1408, 1425, 1431, /* 360 */ 1322, 1555, 1559, 1574, 1574, 1588, 1588, 1588, 2142, 2142, /* 370 */ 2142, 2142, 2142, 2142, 2142, 2142, 2142, 2142, 2142, 2142, /* 380 */ 2142, 2142, 2142, 378, 777, 836, 971, 825, 775, 983, /* 390 */ 1208, 1179, 1217, 1120, 1220, 1206, 1221, 1222, 1226, 1227, /* 400 */ 1228, 1233, 937, 1147, 1261, 1149, 1207, 1248, 1249, 1253, /* 410 */ 1133, 1151, 1274, 1293, 1211, 1236, 1605, 1607, 1589, 1458, /* 420 */ 1599, 1525, 1604, 1600, 1602, 1490, 1492, 1503, 1612, 1504, /* 430 */ 1618, 1510, 1624, 1640, 1513, 1506, 1528, 1593, 1619, 1514, /* 440 */ 1606, 1608, 1610, 1613, 1535, 1551, 1631, 1533, 1667, 1665, /* 450 */ 1649, 1565, 1521, 1609, 1650, 1611, 1603, 1634, 1546, 1573, /* 460 */ 1658, 1663, 1666, 1560, 1568, 1668, 1620, 1669, 1671, 1672, /* 470 */ 1674, 1621, 1661, 1675, 1627, 1662, 1677, 1556, 1679, 1680, /* 480 */ 1548, 1683, 1684, 1682, 1686, 1689, 1688, 1691, 1694, 1693, /* 490 */ 1584, 1696, 1698, 1617, 1695, 1706, 1594, 1705, 1701, 1702, /* 500 */ 1704, 1707, 1647, 1670, 1654, 1708, 1673, 1656, 1715, 1727, /* 510 */ 1729, 1730, 1731, 1733, 1719, 1732, 1705, 1737, 1738, 1742, /* 520 */ 1743, 1741, 1745, 1734, 1758, 1748, 1749, 1750, 1752, 1754, /* 530 */ 1755, 1746, 1655, 1653, 1657, 1659, 1660, 1761, 1773, 1788, }; #define YY_REDUCE_COUNT (382) #define YY_REDUCE_MIN (-260) #define YY_REDUCE_MAX (1420) static const short yy_reduce_ofst[] = { /* 0 */ -170, -18, -159, 309, 313, -167, -19, 75, 117, 211, /* 10 */ 315, 317, -165, -195, -168, -260, 389, 437, 475, 524, /* 20 */ 527, -169, 529, 531, -28, 80, 534, 239, 304, 412, /* 30 */ 558, 577, 37, 120, 368, -22, 460, 517, 555, 560, /* 40 */ 562, 586, -257, -257, -257, -257, -257, -257, -257, -257, /* 50 */ -257, -257, -257, -257, -257, -257, -257, -257, -257, -257, /* 60 */ -257, -257, -257, -257, -257, -257, -257, -257, -257, -257, /* 70 */ -257, -257, -257, -257, -257, -257, -257, -172, 457, 628, /* 80 */ 673, 692, 694, 702, 704, 722, 728, 740, 743, 748, /* 90 */ 767, 791, 815, 818, 820, 822, 857, 861, 864, 866, /* 100 */ 868, 870, 872, 874, 876, 881, 900, 902, 906, 908, /* 110 */ 910, 912, 915, 917, 920, 960, 962, 964, 988, 990, /* 120 */ 992, 1016, 1029, 1032, -257, -257, -257, -257, -257, -257, /* 130 */ -257, -257, -257, 271, 618, -190, 68, 60, 240, -124, /* 140 */ 603, 610, 603, 610, 12, -257, -257, -257, -257, -128, /* 150 */ -128, -128, -142, 25, 270, 281, 333, 124, 236, 648, /* 160 */ 374, 465, 465, 28, 598, 792, 839, 469, 38, 381, /* 170 */ 622, 709, 173, 699, 522, 703, 808, 811, 867, 816, /* 180 */ -104, 823, -3, 875, 649, 753, 323, -88, 882, 884, /* 190 */ 518, 43, 325, 899, 763, 604, 879, 969, 402, -193, /* 200 */ -189, -180, -151, -55, 69, 104, 141, 259, 286, 360, /* 210 */ 364, 455, 474, 481, 510, 516, 611, 653, 788, 99, /* 220 */ 871, 878, 995, 1009, 1049, 1081, 1115, 1134, 1136, 1138, /* 230 */ 1139, 1140, 733, 1110, 1112, 1144, 1145, 1146, 1148, 1084, /* 240 */ 1161, 1162, 1163, 1089, 1047, 1165, 1166, 1127, 1169, 104, /* 250 */ 1181, 1182, 1183, 1184, 1185, 1187, 1098, 1100, 1150, 1131, /* 260 */ 1132, 1135, 1141, 1084, 1150, 1150, 1152, 1173, 1196, 1097, /* 270 */ 1153, 1143, 1167, 1103, 1154, 1155, 1104, 1176, 1174, 1199, /* 280 */ 1178, 1186, 1188, 1168, 1158, 1160, 1170, 1159, 1201, 1230, /* 290 */ 1156, 1243, 1244, 1157, 1164, 1247, 1172, 1189, 1192, 1240, /* 300 */ 1231, 1241, 1242, 1256, 1257, 1278, 1294, 1251, 1252, 1232, /* 310 */ 1234, 1265, 1266, 1259, 1301, 1303, 1223, 1225, 1307, 1313, /* 320 */ 1295, 1317, 1319, 1320, 1323, 1299, 1306, 1308, 1309, 1305, /* 330 */ 1311, 1315, 1314, 1321, 1312, 1324, 1326, 1327, 1263, 1271, /* 340 */ 1331, 1296, 1298, 1300, 1302, 1304, 1310, 1316, 1318, 1357, /* 350 */ 1255, 1260, 1329, 1325, 1332, 1370, 1333, 1338, 1341, 1343, /* 360 */ 1346, 1390, 1393, 1403, 1405, 1416, 1417, 1418, 1328, 1330, /* 370 */ 1335, 1409, 1394, 1399, 1401, 1402, 1410, 1391, 1396, 1411, /* 380 */ 1420, 1413, 1415, }; static const YYACTIONTYPE yy_default[] = { /* 0 */ 1537, 1537, 1537, 1377, 1159, 1266, 1159, 1159, 1159, 1377, /* 10 */ 1377, 1377, 1159, 1296, 1296, 1430, 1190, 1159, 1159, 1159, /* 20 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1376, 1159, 1159, /* 30 */ 1159, 1159, 1460, 1460, 1159, 1159, 1159, 1159, 1159, 1159, /* 40 */ 1159, 1159, 1159, 1302, 1159, 1159, 1159, 1159, 1159, 1378, /* 50 */ 1379, 1159, 1159, 1159, 1429, 1431, 1394, 1312, 1311, 1310, /* 60 */ 1309, 1412, 1283, 1307, 1300, 1304, 1372, 1373, 1371, 1375, /* 70 */ 1379, 1378, 1159, 1303, 1343, 1357, 1342, 1159, 1159, 1159, /* 80 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 90 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 100 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 110 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 120 */ 1159, 1159, 1159, 1159, 1351, 1356, 1362, 1355, 1352, 1345, /* 130 */ 1344, 1346, 1347, 1159, 1180, 1230, 1159, 1159, 1159, 1159, /* 140 */ 1448, 1447, 1159, 1159, 1190, 1348, 1349, 1359, 1358, 1437, /* 150 */ 1493, 1492, 1395, 1159, 1159, 1159, 1159, 1159, 1159, 1460, /* 160 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 170 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 180 */ 1159, 1159, 1159, 1159, 1460, 1460, 1159, 1190, 1460, 1460, /* 190 */ 1186, 1337, 1336, 1186, 1290, 1159, 1443, 1266, 1257, 1159, /* 200 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 210 */ 1159, 1159, 1159, 1434, 1432, 1159, 1159, 1159, 1159, 1159, /* 220 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 230 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 240 */ 1159, 1159, 1159, 1262, 1159, 1159, 1159, 1159, 1159, 1159, /* 250 */ 1159, 1159, 1159, 1159, 1159, 1487, 1159, 1407, 1244, 1262, /* 260 */ 1262, 1262, 1262, 1264, 1245, 1243, 1256, 1191, 1166, 1529, /* 270 */ 1306, 1285, 1285, 1526, 1306, 1306, 1526, 1205, 1507, 1202, /* 280 */ 1296, 1296, 1296, 1285, 1290, 1290, 1374, 1263, 1256, 1159, /* 290 */ 1529, 1271, 1271, 1528, 1528, 1271, 1395, 1315, 1321, 1233, /* 300 */ 1306, 1239, 1239, 1239, 1239, 1271, 1177, 1306, 1306, 1315, /* 310 */ 1321, 1233, 1233, 1306, 1271, 1177, 1411, 1523, 1271, 1177, /* 320 */ 1385, 1271, 1177, 1271, 1177, 1385, 1231, 1231, 1231, 1220, /* 330 */ 1385, 1231, 1205, 1231, 1220, 1231, 1231, 1385, 1389, 1389, /* 340 */ 1385, 1289, 1284, 1289, 1284, 1289, 1284, 1289, 1284, 1271, /* 350 */ 1470, 1470, 1301, 1290, 1380, 1271, 1159, 1301, 1299, 1297, /* 360 */ 1306, 1183, 1223, 1490, 1490, 1486, 1486, 1486, 1534, 1534, /* 370 */ 1443, 1502, 1190, 1190, 1190, 1190, 1502, 1207, 1207, 1191, /* 380 */ 1191, 1190, 1502, 1159, 1159, 1159, 1159, 1159, 1159, 1497, /* 390 */ 1159, 1396, 1275, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 400 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 410 */ 1159, 1159, 1159, 1159, 1159, 1326, 1159, 1162, 1440, 1159, /* 420 */ 1159, 1438, 1159, 1159, 1159, 1159, 1159, 1159, 1276, 1159, /* 430 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 440 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1525, 1159, 1159, /* 450 */ 1159, 1159, 1159, 1159, 1410, 1409, 1159, 1159, 1273, 1159, /* 460 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 470 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 480 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 490 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1298, 1159, 1159, /* 500 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 510 */ 1159, 1159, 1475, 1291, 1159, 1159, 1516, 1159, 1159, 1159, /* 520 */ 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, 1159, /* 530 */ 1159, 1511, 1247, 1328, 1159, 1327, 1331, 1159, 1171, 1159, }; /********** End of lemon-generated parsing tables *****************************/ /* The next table maps tokens (terminal symbols) into fallback tokens. ** If a construct like the following: ** ** %fallback ID X Y Z. |
︙ | ︙ | |||
149764 149765 149766 149767 149768 149769 149770 | /* 197 */ "carglist", /* 198 */ "typetoken", /* 199 */ "typename", /* 200 */ "signed", /* 201 */ "plus_num", /* 202 */ "minus_num", /* 203 */ "scanpt", | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | > | 149911 149912 149913 149914 149915 149916 149917 149918 149919 149920 149921 149922 149923 149924 149925 149926 149927 149928 149929 149930 149931 149932 149933 149934 149935 149936 149937 149938 149939 149940 149941 149942 149943 149944 149945 149946 149947 149948 149949 149950 149951 149952 149953 149954 149955 149956 149957 149958 149959 149960 149961 149962 149963 149964 149965 149966 149967 149968 149969 149970 149971 149972 149973 149974 149975 149976 149977 149978 149979 149980 149981 149982 149983 149984 149985 149986 149987 149988 149989 149990 149991 149992 149993 149994 149995 149996 149997 149998 149999 150000 150001 150002 150003 150004 150005 150006 150007 150008 150009 150010 150011 150012 150013 150014 150015 150016 150017 150018 150019 150020 150021 150022 | /* 197 */ "carglist", /* 198 */ "typetoken", /* 199 */ "typename", /* 200 */ "signed", /* 201 */ "plus_num", /* 202 */ "minus_num", /* 203 */ "scanpt", /* 204 */ "scantok", /* 205 */ "ccons", /* 206 */ "term", /* 207 */ "expr", /* 208 */ "onconf", /* 209 */ "sortorder", /* 210 */ "autoinc", /* 211 */ "eidlist_opt", /* 212 */ "refargs", /* 213 */ "defer_subclause", /* 214 */ "refarg", /* 215 */ "refact", /* 216 */ "init_deferred_pred_opt", /* 217 */ "conslist", /* 218 */ "tconscomma", /* 219 */ "tcons", /* 220 */ "sortlist", /* 221 */ "eidlist", /* 222 */ "defer_subclause_opt", /* 223 */ "orconf", /* 224 */ "resolvetype", /* 225 */ "raisetype", /* 226 */ "ifexists", /* 227 */ "fullname", /* 228 */ "selectnowith", /* 229 */ "oneselect", /* 230 */ "wqlist", /* 231 */ "multiselect_op", /* 232 */ "distinct", /* 233 */ "selcollist", /* 234 */ "from", /* 235 */ "where_opt", /* 236 */ "groupby_opt", /* 237 */ "having_opt", /* 238 */ "orderby_opt", /* 239 */ "limit_opt", /* 240 */ "window_clause", /* 241 */ "values", /* 242 */ "nexprlist", /* 243 */ "sclp", /* 244 */ "as", /* 245 */ "seltablist", /* 246 */ "stl_prefix", /* 247 */ "joinop", /* 248 */ "indexed_opt", /* 249 */ "on_opt", /* 250 */ "using_opt", /* 251 */ "exprlist", /* 252 */ "xfullname", /* 253 */ "idlist", /* 254 */ "with", /* 255 */ "setlist", /* 256 */ "insert_cmd", /* 257 */ "idlist_opt", /* 258 */ "upsert", /* 259 */ "over_clause", /* 260 */ "likeop", /* 261 */ "between_op", /* 262 */ "in_op", /* 263 */ "paren_exprlist", /* 264 */ "case_operand", /* 265 */ "case_exprlist", /* 266 */ "case_else", /* 267 */ "uniqueflag", /* 268 */ "collate", /* 269 */ "vinto", /* 270 */ "nmnum", /* 271 */ "trigger_decl", /* 272 */ "trigger_cmd_list", /* 273 */ "trigger_time", /* 274 */ "trigger_event", /* 275 */ "foreach_clause", /* 276 */ "when_clause", /* 277 */ "trigger_cmd", /* 278 */ "trnm", /* 279 */ "tridxby", /* 280 */ "database_kw_opt", /* 281 */ "key_opt", /* 282 */ "add_column_fullname", /* 283 */ "kwcolumn_opt", /* 284 */ "create_vtab", /* 285 */ "vtabarglist", /* 286 */ "vtabarg", /* 287 */ "vtabargtoken", /* 288 */ "lp", /* 289 */ "anylist", /* 290 */ "windowdefn_list", /* 291 */ "windowdefn", /* 292 */ "window", /* 293 */ "frame_opt", /* 294 */ "part_opt", /* 295 */ "filter_opt", /* 296 */ "range_or_rows", /* 297 */ "frame_bound", /* 298 */ "frame_bound_s", /* 299 */ "frame_bound_e", /* 300 */ "frame_exclude_opt", /* 301 */ "frame_exclude", }; #endif /* defined(YYCOVERAGE) || !defined(NDEBUG) */ #ifndef NDEBUG /* For tracing reduce actions, the names of all rules are required. */ static const char *const yyRuleName[] = { |
︙ | ︙ | |||
149897 149898 149899 149900 149901 149902 149903 | /* 22 */ "table_options ::= WITHOUT nm", /* 23 */ "columnname ::= nm typetoken", /* 24 */ "typetoken ::=", /* 25 */ "typetoken ::= typename LP signed RP", /* 26 */ "typetoken ::= typename LP signed COMMA signed RP", /* 27 */ "typename ::= typename ID|STRING", /* 28 */ "scanpt ::=", | | | | | | | > | | | | | | | < | | | | | | > | < | | | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | | | | | | | | | > | | | | | | < | | | | | | | | | | | | | | | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | | | | | | > | | | | | | | | | < | | | | | | | > | < | | | | | | | | > | | | | | | | | | | | | | | | | | | | | | | | | | < | > | | | | | | | < | | | | | | > | | | | < | | | | | > | | | | | | | | | | | | | | | | | | | < | | | | | > | | | | | | | | | | | | | | | < | > | | | | | | | | | | | | | | | | | < | | | | > | | | | | | | | < | | | | | > | | | | | < | | > | | | | | | | | | | | | | | | | | | | | < | | | | > | | | | | | | | | | | | | | | | | 150045 150046 150047 150048 150049 150050 150051 150052 150053 150054 150055 150056 150057 150058 150059 150060 150061 150062 150063 150064 150065 150066 150067 150068 150069 150070 150071 150072 150073 150074 150075 150076 150077 150078 150079 150080 150081 150082 150083 150084 150085 150086 150087 150088 150089 150090 150091 150092 150093 150094 150095 150096 150097 150098 150099 150100 150101 150102 150103 150104 150105 150106 150107 150108 150109 150110 150111 150112 150113 150114 150115 150116 150117 150118 150119 150120 150121 150122 150123 150124 150125 150126 150127 150128 150129 150130 150131 150132 150133 150134 150135 150136 150137 150138 150139 150140 150141 150142 150143 150144 150145 150146 150147 150148 150149 150150 150151 150152 150153 150154 150155 150156 150157 150158 150159 150160 150161 150162 150163 150164 150165 150166 150167 150168 150169 150170 150171 150172 150173 150174 150175 150176 150177 150178 150179 150180 150181 150182 150183 150184 150185 150186 150187 150188 150189 150190 150191 150192 150193 150194 150195 150196 150197 150198 150199 150200 150201 150202 150203 150204 150205 150206 150207 150208 150209 150210 150211 150212 150213 150214 150215 150216 150217 150218 150219 150220 150221 150222 150223 150224 150225 150226 150227 150228 150229 150230 150231 150232 150233 150234 150235 150236 150237 150238 150239 150240 150241 150242 150243 150244 150245 150246 150247 150248 150249 150250 150251 150252 150253 150254 150255 150256 150257 150258 150259 150260 150261 150262 150263 150264 150265 150266 150267 150268 150269 150270 150271 150272 150273 150274 150275 150276 150277 150278 150279 150280 150281 150282 150283 150284 150285 150286 150287 150288 150289 150290 150291 150292 150293 150294 150295 150296 150297 150298 150299 150300 150301 150302 150303 150304 150305 150306 150307 150308 150309 150310 150311 150312 150313 150314 150315 150316 150317 150318 150319 150320 150321 150322 150323 150324 150325 150326 150327 150328 150329 150330 150331 150332 150333 150334 150335 150336 150337 150338 150339 150340 150341 150342 150343 150344 150345 150346 150347 150348 150349 150350 150351 150352 150353 150354 150355 150356 150357 150358 150359 150360 150361 150362 150363 150364 150365 150366 150367 150368 150369 150370 150371 150372 150373 150374 150375 150376 150377 150378 150379 150380 150381 150382 150383 150384 150385 150386 150387 150388 150389 150390 150391 150392 150393 150394 150395 150396 150397 150398 150399 150400 150401 150402 150403 150404 150405 | /* 22 */ "table_options ::= WITHOUT nm", /* 23 */ "columnname ::= nm typetoken", /* 24 */ "typetoken ::=", /* 25 */ "typetoken ::= typename LP signed RP", /* 26 */ "typetoken ::= typename LP signed COMMA signed RP", /* 27 */ "typename ::= typename ID|STRING", /* 28 */ "scanpt ::=", /* 29 */ "scantok ::=", /* 30 */ "ccons ::= CONSTRAINT nm", /* 31 */ "ccons ::= DEFAULT scantok term", /* 32 */ "ccons ::= DEFAULT LP expr RP", /* 33 */ "ccons ::= DEFAULT PLUS scantok term", /* 34 */ "ccons ::= DEFAULT MINUS scantok term", /* 35 */ "ccons ::= DEFAULT scantok ID|INDEXED", /* 36 */ "ccons ::= NOT NULL onconf", /* 37 */ "ccons ::= PRIMARY KEY sortorder onconf autoinc", /* 38 */ "ccons ::= UNIQUE onconf", /* 39 */ "ccons ::= CHECK LP expr RP", /* 40 */ "ccons ::= REFERENCES nm eidlist_opt refargs", /* 41 */ "ccons ::= defer_subclause", /* 42 */ "ccons ::= COLLATE ID|STRING", /* 43 */ "autoinc ::=", /* 44 */ "autoinc ::= AUTOINCR", /* 45 */ "refargs ::=", /* 46 */ "refargs ::= refargs refarg", /* 47 */ "refarg ::= MATCH nm", /* 48 */ "refarg ::= ON INSERT refact", /* 49 */ "refarg ::= ON DELETE refact", /* 50 */ "refarg ::= ON UPDATE refact", /* 51 */ "refact ::= SET NULL", /* 52 */ "refact ::= SET DEFAULT", /* 53 */ "refact ::= CASCADE", /* 54 */ "refact ::= RESTRICT", /* 55 */ "refact ::= NO ACTION", /* 56 */ "defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt", /* 57 */ "defer_subclause ::= DEFERRABLE init_deferred_pred_opt", /* 58 */ "init_deferred_pred_opt ::=", /* 59 */ "init_deferred_pred_opt ::= INITIALLY DEFERRED", /* 60 */ "init_deferred_pred_opt ::= INITIALLY IMMEDIATE", /* 61 */ "conslist_opt ::=", /* 62 */ "tconscomma ::= COMMA", /* 63 */ "tcons ::= CONSTRAINT nm", /* 64 */ "tcons ::= PRIMARY KEY LP sortlist autoinc RP onconf", /* 65 */ "tcons ::= UNIQUE LP sortlist RP onconf", /* 66 */ "tcons ::= CHECK LP expr RP onconf", /* 67 */ "tcons ::= FOREIGN KEY LP eidlist RP REFERENCES nm eidlist_opt refargs defer_subclause_opt", /* 68 */ "defer_subclause_opt ::=", /* 69 */ "onconf ::=", /* 70 */ "onconf ::= ON CONFLICT resolvetype", /* 71 */ "orconf ::=", /* 72 */ "orconf ::= OR resolvetype", /* 73 */ "resolvetype ::= IGNORE", /* 74 */ "resolvetype ::= REPLACE", /* 75 */ "cmd ::= DROP TABLE ifexists fullname", /* 76 */ "ifexists ::= IF EXISTS", /* 77 */ "ifexists ::=", /* 78 */ "cmd ::= createkw temp VIEW ifnotexists nm dbnm eidlist_opt AS select", /* 79 */ "cmd ::= DROP VIEW ifexists fullname", /* 80 */ "cmd ::= select", /* 81 */ "select ::= WITH wqlist selectnowith", /* 82 */ "select ::= WITH RECURSIVE wqlist selectnowith", /* 83 */ "select ::= selectnowith", /* 84 */ "selectnowith ::= selectnowith multiselect_op oneselect", /* 85 */ "multiselect_op ::= UNION", /* 86 */ "multiselect_op ::= UNION ALL", /* 87 */ "multiselect_op ::= EXCEPT|INTERSECT", /* 88 */ "oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt orderby_opt limit_opt", /* 89 */ "oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt window_clause orderby_opt limit_opt", /* 90 */ "values ::= VALUES LP nexprlist RP", /* 91 */ "values ::= values COMMA LP nexprlist RP", /* 92 */ "distinct ::= DISTINCT", /* 93 */ "distinct ::= ALL", /* 94 */ "distinct ::=", /* 95 */ "sclp ::=", /* 96 */ "selcollist ::= sclp scanpt expr scanpt as", /* 97 */ "selcollist ::= sclp scanpt STAR", /* 98 */ "selcollist ::= sclp scanpt nm DOT STAR", /* 99 */ "as ::= AS nm", /* 100 */ "as ::=", /* 101 */ "from ::=", /* 102 */ "from ::= FROM seltablist", /* 103 */ "stl_prefix ::= seltablist joinop", /* 104 */ "stl_prefix ::=", /* 105 */ "seltablist ::= stl_prefix nm dbnm as indexed_opt on_opt using_opt", /* 106 */ "seltablist ::= stl_prefix nm dbnm LP exprlist RP as on_opt using_opt", /* 107 */ "seltablist ::= stl_prefix LP select RP as on_opt using_opt", /* 108 */ "seltablist ::= stl_prefix LP seltablist RP as on_opt using_opt", /* 109 */ "dbnm ::=", /* 110 */ "dbnm ::= DOT nm", /* 111 */ "fullname ::= nm", /* 112 */ "fullname ::= nm DOT nm", /* 113 */ "xfullname ::= nm", /* 114 */ "xfullname ::= nm DOT nm", /* 115 */ "xfullname ::= nm DOT nm AS nm", /* 116 */ "xfullname ::= nm AS nm", /* 117 */ "joinop ::= COMMA|JOIN", /* 118 */ "joinop ::= JOIN_KW JOIN", /* 119 */ "joinop ::= JOIN_KW nm JOIN", /* 120 */ "joinop ::= JOIN_KW nm nm JOIN", /* 121 */ "on_opt ::= ON expr", /* 122 */ "on_opt ::=", /* 123 */ "indexed_opt ::=", /* 124 */ "indexed_opt ::= INDEXED BY nm", /* 125 */ "indexed_opt ::= NOT INDEXED", /* 126 */ "using_opt ::= USING LP idlist RP", /* 127 */ "using_opt ::=", /* 128 */ "orderby_opt ::=", /* 129 */ "orderby_opt ::= ORDER BY sortlist", /* 130 */ "sortlist ::= sortlist COMMA expr sortorder", /* 131 */ "sortlist ::= expr sortorder", /* 132 */ "sortorder ::= ASC", /* 133 */ "sortorder ::= DESC", /* 134 */ "sortorder ::=", /* 135 */ "groupby_opt ::=", /* 136 */ "groupby_opt ::= GROUP BY nexprlist", /* 137 */ "having_opt ::=", /* 138 */ "having_opt ::= HAVING expr", /* 139 */ "limit_opt ::=", /* 140 */ "limit_opt ::= LIMIT expr", /* 141 */ "limit_opt ::= LIMIT expr OFFSET expr", /* 142 */ "limit_opt ::= LIMIT expr COMMA expr", /* 143 */ "cmd ::= with DELETE FROM xfullname indexed_opt where_opt", /* 144 */ "where_opt ::=", /* 145 */ "where_opt ::= WHERE expr", /* 146 */ "cmd ::= with UPDATE orconf xfullname indexed_opt SET setlist where_opt", /* 147 */ "setlist ::= setlist COMMA nm EQ expr", /* 148 */ "setlist ::= setlist COMMA LP idlist RP EQ expr", /* 149 */ "setlist ::= nm EQ expr", /* 150 */ "setlist ::= LP idlist RP EQ expr", /* 151 */ "cmd ::= with insert_cmd INTO xfullname idlist_opt select upsert", /* 152 */ "cmd ::= with insert_cmd INTO xfullname idlist_opt DEFAULT VALUES", /* 153 */ "upsert ::=", /* 154 */ "upsert ::= ON CONFLICT LP sortlist RP where_opt DO UPDATE SET setlist where_opt", /* 155 */ "upsert ::= ON CONFLICT LP sortlist RP where_opt DO NOTHING", /* 156 */ "upsert ::= ON CONFLICT DO NOTHING", /* 157 */ "insert_cmd ::= INSERT orconf", /* 158 */ "insert_cmd ::= REPLACE", /* 159 */ "idlist_opt ::=", /* 160 */ "idlist_opt ::= LP idlist RP", /* 161 */ "idlist ::= idlist COMMA nm", /* 162 */ "idlist ::= nm", /* 163 */ "expr ::= LP expr RP", /* 164 */ "expr ::= ID|INDEXED", /* 165 */ "expr ::= JOIN_KW", /* 166 */ "expr ::= nm DOT nm", /* 167 */ "expr ::= nm DOT nm DOT nm", /* 168 */ "term ::= NULL|FLOAT|BLOB", /* 169 */ "term ::= STRING", /* 170 */ "term ::= INTEGER", /* 171 */ "expr ::= VARIABLE", /* 172 */ "expr ::= expr COLLATE ID|STRING", /* 173 */ "expr ::= CAST LP expr AS typetoken RP", /* 174 */ "expr ::= ID|INDEXED LP distinct exprlist RP", /* 175 */ "expr ::= ID|INDEXED LP STAR RP", /* 176 */ "expr ::= ID|INDEXED LP distinct exprlist RP over_clause", /* 177 */ "expr ::= ID|INDEXED LP STAR RP over_clause", /* 178 */ "term ::= CTIME_KW", /* 179 */ "expr ::= LP nexprlist COMMA expr RP", /* 180 */ "expr ::= expr AND expr", /* 181 */ "expr ::= expr OR expr", /* 182 */ "expr ::= expr LT|GT|GE|LE expr", /* 183 */ "expr ::= expr EQ|NE expr", /* 184 */ "expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr", /* 185 */ "expr ::= expr PLUS|MINUS expr", /* 186 */ "expr ::= expr STAR|SLASH|REM expr", /* 187 */ "expr ::= expr CONCAT expr", /* 188 */ "likeop ::= NOT LIKE_KW|MATCH", /* 189 */ "expr ::= expr likeop expr", /* 190 */ "expr ::= expr likeop expr ESCAPE expr", /* 191 */ "expr ::= expr ISNULL|NOTNULL", /* 192 */ "expr ::= expr NOT NULL", /* 193 */ "expr ::= expr IS expr", /* 194 */ "expr ::= expr IS NOT expr", /* 195 */ "expr ::= NOT expr", /* 196 */ "expr ::= BITNOT expr", /* 197 */ "expr ::= PLUS|MINUS expr", /* 198 */ "between_op ::= BETWEEN", /* 199 */ "between_op ::= NOT BETWEEN", /* 200 */ "expr ::= expr between_op expr AND expr", /* 201 */ "in_op ::= IN", /* 202 */ "in_op ::= NOT IN", /* 203 */ "expr ::= expr in_op LP exprlist RP", /* 204 */ "expr ::= LP select RP", /* 205 */ "expr ::= expr in_op LP select RP", /* 206 */ "expr ::= expr in_op nm dbnm paren_exprlist", /* 207 */ "expr ::= EXISTS LP select RP", /* 208 */ "expr ::= CASE case_operand case_exprlist case_else END", /* 209 */ "case_exprlist ::= case_exprlist WHEN expr THEN expr", /* 210 */ "case_exprlist ::= WHEN expr THEN expr", /* 211 */ "case_else ::= ELSE expr", /* 212 */ "case_else ::=", /* 213 */ "case_operand ::= expr", /* 214 */ "case_operand ::=", /* 215 */ "exprlist ::=", /* 216 */ "nexprlist ::= nexprlist COMMA expr", /* 217 */ "nexprlist ::= expr", /* 218 */ "paren_exprlist ::=", /* 219 */ "paren_exprlist ::= LP exprlist RP", /* 220 */ "cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP sortlist RP where_opt", /* 221 */ "uniqueflag ::= UNIQUE", /* 222 */ "uniqueflag ::=", /* 223 */ "eidlist_opt ::=", /* 224 */ "eidlist_opt ::= LP eidlist RP", /* 225 */ "eidlist ::= eidlist COMMA nm collate sortorder", /* 226 */ "eidlist ::= nm collate sortorder", /* 227 */ "collate ::=", /* 228 */ "collate ::= COLLATE ID|STRING", /* 229 */ "cmd ::= DROP INDEX ifexists fullname", /* 230 */ "cmd ::= VACUUM vinto", /* 231 */ "cmd ::= VACUUM nm vinto", /* 232 */ "vinto ::= INTO expr", /* 233 */ "vinto ::=", /* 234 */ "cmd ::= PRAGMA nm dbnm", /* 235 */ "cmd ::= PRAGMA nm dbnm EQ nmnum", /* 236 */ "cmd ::= PRAGMA nm dbnm LP nmnum RP", /* 237 */ "cmd ::= PRAGMA nm dbnm EQ minus_num", /* 238 */ "cmd ::= PRAGMA nm dbnm LP minus_num RP", /* 239 */ "plus_num ::= PLUS INTEGER|FLOAT", /* 240 */ "minus_num ::= MINUS INTEGER|FLOAT", /* 241 */ "cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END", /* 242 */ "trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause", /* 243 */ "trigger_time ::= BEFORE|AFTER", /* 244 */ "trigger_time ::= INSTEAD OF", /* 245 */ "trigger_time ::=", /* 246 */ "trigger_event ::= DELETE|INSERT", /* 247 */ "trigger_event ::= UPDATE", /* 248 */ "trigger_event ::= UPDATE OF idlist", /* 249 */ "when_clause ::=", /* 250 */ "when_clause ::= WHEN expr", /* 251 */ "trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI", /* 252 */ "trigger_cmd_list ::= trigger_cmd SEMI", /* 253 */ "trnm ::= nm DOT nm", /* 254 */ "tridxby ::= INDEXED BY nm", /* 255 */ "tridxby ::= NOT INDEXED", /* 256 */ "trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt scanpt", /* 257 */ "trigger_cmd ::= scanpt insert_cmd INTO trnm idlist_opt select upsert scanpt", /* 258 */ "trigger_cmd ::= DELETE FROM trnm tridxby where_opt scanpt", /* 259 */ "trigger_cmd ::= scanpt select scanpt", /* 260 */ "expr ::= RAISE LP IGNORE RP", /* 261 */ "expr ::= RAISE LP raisetype COMMA nm RP", /* 262 */ "raisetype ::= ROLLBACK", /* 263 */ "raisetype ::= ABORT", /* 264 */ "raisetype ::= FAIL", /* 265 */ "cmd ::= DROP TRIGGER ifexists fullname", /* 266 */ "cmd ::= ATTACH database_kw_opt expr AS expr key_opt", /* 267 */ "cmd ::= DETACH database_kw_opt expr", /* 268 */ "key_opt ::=", /* 269 */ "key_opt ::= KEY expr", /* 270 */ "cmd ::= REINDEX", /* 271 */ "cmd ::= REINDEX nm dbnm", /* 272 */ "cmd ::= ANALYZE", /* 273 */ "cmd ::= ANALYZE nm dbnm", /* 274 */ "cmd ::= ALTER TABLE fullname RENAME TO nm", /* 275 */ "cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt columnname carglist", /* 276 */ "add_column_fullname ::= fullname", /* 277 */ "cmd ::= ALTER TABLE fullname RENAME kwcolumn_opt nm TO nm", /* 278 */ "cmd ::= create_vtab", /* 279 */ "cmd ::= create_vtab LP vtabarglist RP", /* 280 */ "create_vtab ::= createkw VIRTUAL TABLE ifnotexists nm dbnm USING nm", /* 281 */ "vtabarg ::=", /* 282 */ "vtabargtoken ::= ANY", /* 283 */ "vtabargtoken ::= lp anylist RP", /* 284 */ "lp ::= LP", /* 285 */ "with ::= WITH wqlist", /* 286 */ "with ::= WITH RECURSIVE wqlist", /* 287 */ "wqlist ::= nm eidlist_opt AS LP select RP", /* 288 */ "wqlist ::= wqlist COMMA nm eidlist_opt AS LP select RP", /* 289 */ "windowdefn_list ::= windowdefn", /* 290 */ "windowdefn_list ::= windowdefn_list COMMA windowdefn", /* 291 */ "windowdefn ::= nm AS LP window RP", /* 292 */ "window ::= PARTITION BY nexprlist orderby_opt frame_opt", /* 293 */ "window ::= nm PARTITION BY nexprlist orderby_opt frame_opt", /* 294 */ "window ::= ORDER BY sortlist frame_opt", /* 295 */ "window ::= nm ORDER BY sortlist frame_opt", /* 296 */ "window ::= frame_opt", /* 297 */ "window ::= nm frame_opt", /* 298 */ "frame_opt ::=", /* 299 */ "frame_opt ::= range_or_rows frame_bound_s frame_exclude_opt", /* 300 */ "frame_opt ::= range_or_rows BETWEEN frame_bound_s AND frame_bound_e frame_exclude_opt", /* 301 */ "range_or_rows ::= RANGE|ROWS|GROUPS", /* 302 */ "frame_bound_s ::= frame_bound", /* 303 */ "frame_bound_s ::= UNBOUNDED PRECEDING", /* 304 */ "frame_bound_e ::= frame_bound", /* 305 */ "frame_bound_e ::= UNBOUNDED FOLLOWING", /* 306 */ "frame_bound ::= expr PRECEDING|FOLLOWING", /* 307 */ "frame_bound ::= CURRENT ROW", /* 308 */ "frame_exclude_opt ::=", /* 309 */ "frame_exclude_opt ::= EXCLUDE frame_exclude", /* 310 */ "frame_exclude ::= NO OTHERS", /* 311 */ "frame_exclude ::= CURRENT ROW", /* 312 */ "frame_exclude ::= GROUP|TIES", /* 313 */ "window_clause ::= WINDOW windowdefn_list", /* 314 */ "over_clause ::= filter_opt OVER LP window RP", /* 315 */ "over_clause ::= filter_opt OVER nm", /* 316 */ "filter_opt ::=", /* 317 */ "filter_opt ::= FILTER LP WHERE expr RP", /* 318 */ "input ::= cmdlist", /* 319 */ "cmdlist ::= cmdlist ecmd", /* 320 */ "cmdlist ::= ecmd", /* 321 */ "ecmd ::= SEMI", /* 322 */ "ecmd ::= cmdx SEMI", /* 323 */ "ecmd ::= explain cmdx", /* 324 */ "trans_opt ::=", /* 325 */ "trans_opt ::= TRANSACTION", /* 326 */ "trans_opt ::= TRANSACTION nm", /* 327 */ "savepoint_opt ::= SAVEPOINT", /* 328 */ "savepoint_opt ::=", /* 329 */ "cmd ::= create_table create_table_args", /* 330 */ "columnlist ::= columnlist COMMA columnname carglist", /* 331 */ "columnlist ::= columnname carglist", /* 332 */ "nm ::= ID|INDEXED", /* 333 */ "nm ::= STRING", /* 334 */ "nm ::= JOIN_KW", /* 335 */ "typetoken ::= typename", /* 336 */ "typename ::= ID|STRING", /* 337 */ "signed ::= plus_num", /* 338 */ "signed ::= minus_num", /* 339 */ "carglist ::= carglist ccons", /* 340 */ "carglist ::=", /* 341 */ "ccons ::= NULL onconf", /* 342 */ "conslist_opt ::= COMMA conslist", /* 343 */ "conslist ::= conslist tconscomma tcons", /* 344 */ "conslist ::= tcons", /* 345 */ "tconscomma ::=", /* 346 */ "defer_subclause_opt ::= defer_subclause", /* 347 */ "resolvetype ::= raisetype", /* 348 */ "selectnowith ::= oneselect", /* 349 */ "oneselect ::= values", /* 350 */ "sclp ::= selcollist COMMA", /* 351 */ "as ::= ID|STRING", /* 352 */ "expr ::= term", /* 353 */ "likeop ::= LIKE_KW|MATCH", /* 354 */ "exprlist ::= nexprlist", /* 355 */ "nmnum ::= plus_num", /* 356 */ "nmnum ::= nm", /* 357 */ "nmnum ::= ON", /* 358 */ "nmnum ::= DELETE", /* 359 */ "nmnum ::= DEFAULT", /* 360 */ "plus_num ::= INTEGER|FLOAT", /* 361 */ "foreach_clause ::=", /* 362 */ "foreach_clause ::= FOR EACH ROW", /* 363 */ "trnm ::= nm", /* 364 */ "tridxby ::=", /* 365 */ "database_kw_opt ::= DATABASE", /* 366 */ "database_kw_opt ::=", /* 367 */ "kwcolumn_opt ::=", /* 368 */ "kwcolumn_opt ::= COLUMNKW", /* 369 */ "vtabarglist ::= vtabarg", /* 370 */ "vtabarglist ::= vtabarglist COMMA vtabarg", /* 371 */ "vtabarg ::= vtabarg vtabargtoken", /* 372 */ "anylist ::=", /* 373 */ "anylist ::= anylist LP anylist RP", /* 374 */ "anylist ::= anylist ANY", /* 375 */ "with ::=", }; #endif /* NDEBUG */ #if YYSTACKDEPTH<=0 /* ** Try to increase the size of the parser stack. Return the number |
︙ | ︙ | |||
150369 150370 150371 150372 150373 150374 150375 | ** ** Note: during a reduce, the only symbols destroyed are those ** which appear on the RHS of the rule, but which are *not* used ** inside the C code. */ /********* Begin destructor definitions ***************************************/ case 195: /* select */ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | > | | | | | | | | | | | 150518 150519 150520 150521 150522 150523 150524 150525 150526 150527 150528 150529 150530 150531 150532 150533 150534 150535 150536 150537 150538 150539 150540 150541 150542 150543 150544 150545 150546 150547 150548 150549 150550 150551 150552 150553 150554 150555 150556 150557 150558 150559 150560 150561 150562 150563 150564 150565 150566 150567 150568 150569 150570 150571 150572 150573 150574 150575 150576 150577 150578 150579 150580 150581 150582 150583 150584 150585 150586 150587 150588 150589 150590 150591 150592 150593 150594 150595 150596 150597 150598 150599 150600 150601 150602 150603 150604 150605 150606 150607 150608 150609 150610 150611 150612 150613 150614 150615 150616 150617 150618 150619 150620 150621 | ** ** Note: during a reduce, the only symbols destroyed are those ** which appear on the RHS of the rule, but which are *not* used ** inside the C code. */ /********* Begin destructor definitions ***************************************/ case 195: /* select */ case 228: /* selectnowith */ case 229: /* oneselect */ case 241: /* values */ { sqlite3SelectDelete(pParse->db, (yypminor->yy391)); } break; case 206: /* term */ case 207: /* expr */ case 235: /* where_opt */ case 237: /* having_opt */ case 249: /* on_opt */ case 264: /* case_operand */ case 266: /* case_else */ case 269: /* vinto */ case 276: /* when_clause */ case 281: /* key_opt */ case 295: /* filter_opt */ { sqlite3ExprDelete(pParse->db, (yypminor->yy102)); } break; case 211: /* eidlist_opt */ case 220: /* sortlist */ case 221: /* eidlist */ case 233: /* selcollist */ case 236: /* groupby_opt */ case 238: /* orderby_opt */ case 242: /* nexprlist */ case 243: /* sclp */ case 251: /* exprlist */ case 255: /* setlist */ case 263: /* paren_exprlist */ case 265: /* case_exprlist */ case 294: /* part_opt */ { sqlite3ExprListDelete(pParse->db, (yypminor->yy94)); } break; case 227: /* fullname */ case 234: /* from */ case 245: /* seltablist */ case 246: /* stl_prefix */ case 252: /* xfullname */ { sqlite3SrcListDelete(pParse->db, (yypminor->yy407)); } break; case 230: /* wqlist */ { sqlite3WithDelete(pParse->db, (yypminor->yy243)); } break; case 240: /* window_clause */ case 290: /* windowdefn_list */ { sqlite3WindowListDelete(pParse->db, (yypminor->yy379)); } break; case 250: /* using_opt */ case 253: /* idlist */ case 257: /* idlist_opt */ { sqlite3IdListDelete(pParse->db, (yypminor->yy76)); } break; case 259: /* over_clause */ case 291: /* windowdefn */ case 292: /* window */ case 293: /* frame_opt */ { sqlite3WindowDelete(pParse->db, (yypminor->yy379)); } break; case 272: /* trigger_cmd_list */ case 277: /* trigger_cmd */ { sqlite3DeleteTriggerStep(pParse->db, (yypminor->yy11)); } break; case 274: /* trigger_event */ { sqlite3IdListDelete(pParse->db, (yypminor->yy298).b); } break; case 297: /* frame_bound */ case 298: /* frame_bound_s */ case 299: /* frame_bound_e */ { sqlite3ExprDelete(pParse->db, (yypminor->yy389).pExpr); } break; /********* End destructor definitions *****************************************/ default: break; /* If no destructor action specified: do nothing */ } } |
︙ | ︙ | |||
150782 150783 150784 150785 150786 150787 150788 | 194, /* (22) table_options ::= WITHOUT nm */ 196, /* (23) columnname ::= nm typetoken */ 198, /* (24) typetoken ::= */ 198, /* (25) typetoken ::= typename LP signed RP */ 198, /* (26) typetoken ::= typename LP signed COMMA signed RP */ 199, /* (27) typename ::= typename ID|STRING */ 203, /* (28) scanpt ::= */ | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < > | | | | | | | | | | < | | | | > | | | | | < | | | | > | | | | | | | | | | | | | | | | | | | | | < | | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | | | | | | > | | | | | < | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 150931 150932 150933 150934 150935 150936 150937 150938 150939 150940 150941 150942 150943 150944 150945 150946 150947 150948 150949 150950 150951 150952 150953 150954 150955 150956 150957 150958 150959 150960 150961 150962 150963 150964 150965 150966 150967 150968 150969 150970 150971 150972 150973 150974 150975 150976 150977 150978 150979 150980 150981 150982 150983 150984 150985 150986 150987 150988 150989 150990 150991 150992 150993 150994 150995 150996 150997 150998 150999 151000 151001 151002 151003 151004 151005 151006 151007 151008 151009 151010 151011 151012 151013 151014 151015 151016 151017 151018 151019 151020 151021 151022 151023 151024 151025 151026 151027 151028 151029 151030 151031 151032 151033 151034 151035 151036 151037 151038 151039 151040 151041 151042 151043 151044 151045 151046 151047 151048 151049 151050 151051 151052 151053 151054 151055 151056 151057 151058 151059 151060 151061 151062 151063 151064 151065 151066 151067 151068 151069 151070 151071 151072 151073 151074 151075 151076 151077 151078 151079 151080 151081 151082 151083 151084 151085 151086 151087 151088 151089 151090 151091 151092 151093 151094 151095 151096 151097 151098 151099 151100 151101 151102 151103 151104 151105 151106 151107 151108 151109 151110 151111 151112 151113 151114 151115 151116 151117 151118 151119 151120 151121 151122 151123 151124 151125 151126 151127 151128 151129 151130 151131 151132 151133 151134 151135 151136 151137 151138 151139 151140 151141 151142 151143 151144 151145 151146 151147 151148 151149 151150 151151 151152 151153 151154 151155 151156 151157 151158 151159 151160 151161 151162 151163 151164 151165 151166 151167 151168 151169 151170 151171 151172 151173 151174 151175 151176 151177 151178 151179 151180 151181 151182 151183 151184 151185 151186 151187 151188 151189 151190 151191 151192 151193 151194 151195 151196 151197 151198 151199 151200 151201 151202 151203 151204 151205 151206 151207 151208 151209 151210 151211 151212 151213 151214 151215 151216 151217 151218 151219 151220 151221 151222 151223 151224 151225 151226 151227 151228 151229 151230 151231 151232 151233 151234 151235 151236 151237 151238 151239 151240 151241 151242 151243 151244 151245 151246 151247 151248 151249 151250 151251 151252 151253 151254 151255 151256 151257 151258 151259 151260 151261 151262 151263 151264 151265 151266 151267 151268 151269 151270 151271 151272 151273 151274 151275 151276 151277 151278 151279 151280 151281 151282 151283 151284 151285 151286 151287 151288 151289 151290 151291 | 194, /* (22) table_options ::= WITHOUT nm */ 196, /* (23) columnname ::= nm typetoken */ 198, /* (24) typetoken ::= */ 198, /* (25) typetoken ::= typename LP signed RP */ 198, /* (26) typetoken ::= typename LP signed COMMA signed RP */ 199, /* (27) typename ::= typename ID|STRING */ 203, /* (28) scanpt ::= */ 204, /* (29) scantok ::= */ 205, /* (30) ccons ::= CONSTRAINT nm */ 205, /* (31) ccons ::= DEFAULT scantok term */ 205, /* (32) ccons ::= DEFAULT LP expr RP */ 205, /* (33) ccons ::= DEFAULT PLUS scantok term */ 205, /* (34) ccons ::= DEFAULT MINUS scantok term */ 205, /* (35) ccons ::= DEFAULT scantok ID|INDEXED */ 205, /* (36) ccons ::= NOT NULL onconf */ 205, /* (37) ccons ::= PRIMARY KEY sortorder onconf autoinc */ 205, /* (38) ccons ::= UNIQUE onconf */ 205, /* (39) ccons ::= CHECK LP expr RP */ 205, /* (40) ccons ::= REFERENCES nm eidlist_opt refargs */ 205, /* (41) ccons ::= defer_subclause */ 205, /* (42) ccons ::= COLLATE ID|STRING */ 210, /* (43) autoinc ::= */ 210, /* (44) autoinc ::= AUTOINCR */ 212, /* (45) refargs ::= */ 212, /* (46) refargs ::= refargs refarg */ 214, /* (47) refarg ::= MATCH nm */ 214, /* (48) refarg ::= ON INSERT refact */ 214, /* (49) refarg ::= ON DELETE refact */ 214, /* (50) refarg ::= ON UPDATE refact */ 215, /* (51) refact ::= SET NULL */ 215, /* (52) refact ::= SET DEFAULT */ 215, /* (53) refact ::= CASCADE */ 215, /* (54) refact ::= RESTRICT */ 215, /* (55) refact ::= NO ACTION */ 213, /* (56) defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt */ 213, /* (57) defer_subclause ::= DEFERRABLE init_deferred_pred_opt */ 216, /* (58) init_deferred_pred_opt ::= */ 216, /* (59) init_deferred_pred_opt ::= INITIALLY DEFERRED */ 216, /* (60) init_deferred_pred_opt ::= INITIALLY IMMEDIATE */ 193, /* (61) conslist_opt ::= */ 218, /* (62) tconscomma ::= COMMA */ 219, /* (63) tcons ::= CONSTRAINT nm */ 219, /* (64) tcons ::= PRIMARY KEY LP sortlist autoinc RP onconf */ 219, /* (65) tcons ::= UNIQUE LP sortlist RP onconf */ 219, /* (66) tcons ::= CHECK LP expr RP onconf */ 219, /* (67) tcons ::= FOREIGN KEY LP eidlist RP REFERENCES nm eidlist_opt refargs defer_subclause_opt */ 222, /* (68) defer_subclause_opt ::= */ 208, /* (69) onconf ::= */ 208, /* (70) onconf ::= ON CONFLICT resolvetype */ 223, /* (71) orconf ::= */ 223, /* (72) orconf ::= OR resolvetype */ 224, /* (73) resolvetype ::= IGNORE */ 224, /* (74) resolvetype ::= REPLACE */ 181, /* (75) cmd ::= DROP TABLE ifexists fullname */ 226, /* (76) ifexists ::= IF EXISTS */ 226, /* (77) ifexists ::= */ 181, /* (78) cmd ::= createkw temp VIEW ifnotexists nm dbnm eidlist_opt AS select */ 181, /* (79) cmd ::= DROP VIEW ifexists fullname */ 181, /* (80) cmd ::= select */ 195, /* (81) select ::= WITH wqlist selectnowith */ 195, /* (82) select ::= WITH RECURSIVE wqlist selectnowith */ 195, /* (83) select ::= selectnowith */ 228, /* (84) selectnowith ::= selectnowith multiselect_op oneselect */ 231, /* (85) multiselect_op ::= UNION */ 231, /* (86) multiselect_op ::= UNION ALL */ 231, /* (87) multiselect_op ::= EXCEPT|INTERSECT */ 229, /* (88) oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt orderby_opt limit_opt */ 229, /* (89) oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt window_clause orderby_opt limit_opt */ 241, /* (90) values ::= VALUES LP nexprlist RP */ 241, /* (91) values ::= values COMMA LP nexprlist RP */ 232, /* (92) distinct ::= DISTINCT */ 232, /* (93) distinct ::= ALL */ 232, /* (94) distinct ::= */ 243, /* (95) sclp ::= */ 233, /* (96) selcollist ::= sclp scanpt expr scanpt as */ 233, /* (97) selcollist ::= sclp scanpt STAR */ 233, /* (98) selcollist ::= sclp scanpt nm DOT STAR */ 244, /* (99) as ::= AS nm */ 244, /* (100) as ::= */ 234, /* (101) from ::= */ 234, /* (102) from ::= FROM seltablist */ 246, /* (103) stl_prefix ::= seltablist joinop */ 246, /* (104) stl_prefix ::= */ 245, /* (105) seltablist ::= stl_prefix nm dbnm as indexed_opt on_opt using_opt */ 245, /* (106) seltablist ::= stl_prefix nm dbnm LP exprlist RP as on_opt using_opt */ 245, /* (107) seltablist ::= stl_prefix LP select RP as on_opt using_opt */ 245, /* (108) seltablist ::= stl_prefix LP seltablist RP as on_opt using_opt */ 191, /* (109) dbnm ::= */ 191, /* (110) dbnm ::= DOT nm */ 227, /* (111) fullname ::= nm */ 227, /* (112) fullname ::= nm DOT nm */ 252, /* (113) xfullname ::= nm */ 252, /* (114) xfullname ::= nm DOT nm */ 252, /* (115) xfullname ::= nm DOT nm AS nm */ 252, /* (116) xfullname ::= nm AS nm */ 247, /* (117) joinop ::= COMMA|JOIN */ 247, /* (118) joinop ::= JOIN_KW JOIN */ 247, /* (119) joinop ::= JOIN_KW nm JOIN */ 247, /* (120) joinop ::= JOIN_KW nm nm JOIN */ 249, /* (121) on_opt ::= ON expr */ 249, /* (122) on_opt ::= */ 248, /* (123) indexed_opt ::= */ 248, /* (124) indexed_opt ::= INDEXED BY nm */ 248, /* (125) indexed_opt ::= NOT INDEXED */ 250, /* (126) using_opt ::= USING LP idlist RP */ 250, /* (127) using_opt ::= */ 238, /* (128) orderby_opt ::= */ 238, /* (129) orderby_opt ::= ORDER BY sortlist */ 220, /* (130) sortlist ::= sortlist COMMA expr sortorder */ 220, /* (131) sortlist ::= expr sortorder */ 209, /* (132) sortorder ::= ASC */ 209, /* (133) sortorder ::= DESC */ 209, /* (134) sortorder ::= */ 236, /* (135) groupby_opt ::= */ 236, /* (136) groupby_opt ::= GROUP BY nexprlist */ 237, /* (137) having_opt ::= */ 237, /* (138) having_opt ::= HAVING expr */ 239, /* (139) limit_opt ::= */ 239, /* (140) limit_opt ::= LIMIT expr */ 239, /* (141) limit_opt ::= LIMIT expr OFFSET expr */ 239, /* (142) limit_opt ::= LIMIT expr COMMA expr */ 181, /* (143) cmd ::= with DELETE FROM xfullname indexed_opt where_opt */ 235, /* (144) where_opt ::= */ 235, /* (145) where_opt ::= WHERE expr */ 181, /* (146) cmd ::= with UPDATE orconf xfullname indexed_opt SET setlist where_opt */ 255, /* (147) setlist ::= setlist COMMA nm EQ expr */ 255, /* (148) setlist ::= setlist COMMA LP idlist RP EQ expr */ 255, /* (149) setlist ::= nm EQ expr */ 255, /* (150) setlist ::= LP idlist RP EQ expr */ 181, /* (151) cmd ::= with insert_cmd INTO xfullname idlist_opt select upsert */ 181, /* (152) cmd ::= with insert_cmd INTO xfullname idlist_opt DEFAULT VALUES */ 258, /* (153) upsert ::= */ 258, /* (154) upsert ::= ON CONFLICT LP sortlist RP where_opt DO UPDATE SET setlist where_opt */ 258, /* (155) upsert ::= ON CONFLICT LP sortlist RP where_opt DO NOTHING */ 258, /* (156) upsert ::= ON CONFLICT DO NOTHING */ 256, /* (157) insert_cmd ::= INSERT orconf */ 256, /* (158) insert_cmd ::= REPLACE */ 257, /* (159) idlist_opt ::= */ 257, /* (160) idlist_opt ::= LP idlist RP */ 253, /* (161) idlist ::= idlist COMMA nm */ 253, /* (162) idlist ::= nm */ 207, /* (163) expr ::= LP expr RP */ 207, /* (164) expr ::= ID|INDEXED */ 207, /* (165) expr ::= JOIN_KW */ 207, /* (166) expr ::= nm DOT nm */ 207, /* (167) expr ::= nm DOT nm DOT nm */ 206, /* (168) term ::= NULL|FLOAT|BLOB */ 206, /* (169) term ::= STRING */ 206, /* (170) term ::= INTEGER */ 207, /* (171) expr ::= VARIABLE */ 207, /* (172) expr ::= expr COLLATE ID|STRING */ 207, /* (173) expr ::= CAST LP expr AS typetoken RP */ 207, /* (174) expr ::= ID|INDEXED LP distinct exprlist RP */ 207, /* (175) expr ::= ID|INDEXED LP STAR RP */ 207, /* (176) expr ::= ID|INDEXED LP distinct exprlist RP over_clause */ 207, /* (177) expr ::= ID|INDEXED LP STAR RP over_clause */ 206, /* (178) term ::= CTIME_KW */ 207, /* (179) expr ::= LP nexprlist COMMA expr RP */ 207, /* (180) expr ::= expr AND expr */ 207, /* (181) expr ::= expr OR expr */ 207, /* (182) expr ::= expr LT|GT|GE|LE expr */ 207, /* (183) expr ::= expr EQ|NE expr */ 207, /* (184) expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr */ 207, /* (185) expr ::= expr PLUS|MINUS expr */ 207, /* (186) expr ::= expr STAR|SLASH|REM expr */ 207, /* (187) expr ::= expr CONCAT expr */ 260, /* (188) likeop ::= NOT LIKE_KW|MATCH */ 207, /* (189) expr ::= expr likeop expr */ 207, /* (190) expr ::= expr likeop expr ESCAPE expr */ 207, /* (191) expr ::= expr ISNULL|NOTNULL */ 207, /* (192) expr ::= expr NOT NULL */ 207, /* (193) expr ::= expr IS expr */ 207, /* (194) expr ::= expr IS NOT expr */ 207, /* (195) expr ::= NOT expr */ 207, /* (196) expr ::= BITNOT expr */ 207, /* (197) expr ::= PLUS|MINUS expr */ 261, /* (198) between_op ::= BETWEEN */ 261, /* (199) between_op ::= NOT BETWEEN */ 207, /* (200) expr ::= expr between_op expr AND expr */ 262, /* (201) in_op ::= IN */ 262, /* (202) in_op ::= NOT IN */ 207, /* (203) expr ::= expr in_op LP exprlist RP */ 207, /* (204) expr ::= LP select RP */ 207, /* (205) expr ::= expr in_op LP select RP */ 207, /* (206) expr ::= expr in_op nm dbnm paren_exprlist */ 207, /* (207) expr ::= EXISTS LP select RP */ 207, /* (208) expr ::= CASE case_operand case_exprlist case_else END */ 265, /* (209) case_exprlist ::= case_exprlist WHEN expr THEN expr */ 265, /* (210) case_exprlist ::= WHEN expr THEN expr */ 266, /* (211) case_else ::= ELSE expr */ 266, /* (212) case_else ::= */ 264, /* (213) case_operand ::= expr */ 264, /* (214) case_operand ::= */ 251, /* (215) exprlist ::= */ 242, /* (216) nexprlist ::= nexprlist COMMA expr */ 242, /* (217) nexprlist ::= expr */ 263, /* (218) paren_exprlist ::= */ 263, /* (219) paren_exprlist ::= LP exprlist RP */ 181, /* (220) cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP sortlist RP where_opt */ 267, /* (221) uniqueflag ::= UNIQUE */ 267, /* (222) uniqueflag ::= */ 211, /* (223) eidlist_opt ::= */ 211, /* (224) eidlist_opt ::= LP eidlist RP */ 221, /* (225) eidlist ::= eidlist COMMA nm collate sortorder */ 221, /* (226) eidlist ::= nm collate sortorder */ 268, /* (227) collate ::= */ 268, /* (228) collate ::= COLLATE ID|STRING */ 181, /* (229) cmd ::= DROP INDEX ifexists fullname */ 181, /* (230) cmd ::= VACUUM vinto */ 181, /* (231) cmd ::= VACUUM nm vinto */ 269, /* (232) vinto ::= INTO expr */ 269, /* (233) vinto ::= */ 181, /* (234) cmd ::= PRAGMA nm dbnm */ 181, /* (235) cmd ::= PRAGMA nm dbnm EQ nmnum */ 181, /* (236) cmd ::= PRAGMA nm dbnm LP nmnum RP */ 181, /* (237) cmd ::= PRAGMA nm dbnm EQ minus_num */ 181, /* (238) cmd ::= PRAGMA nm dbnm LP minus_num RP */ 201, /* (239) plus_num ::= PLUS INTEGER|FLOAT */ 202, /* (240) minus_num ::= MINUS INTEGER|FLOAT */ 181, /* (241) cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END */ 271, /* (242) trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause */ 273, /* (243) trigger_time ::= BEFORE|AFTER */ 273, /* (244) trigger_time ::= INSTEAD OF */ 273, /* (245) trigger_time ::= */ 274, /* (246) trigger_event ::= DELETE|INSERT */ 274, /* (247) trigger_event ::= UPDATE */ 274, /* (248) trigger_event ::= UPDATE OF idlist */ 276, /* (249) when_clause ::= */ 276, /* (250) when_clause ::= WHEN expr */ 272, /* (251) trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI */ 272, /* (252) trigger_cmd_list ::= trigger_cmd SEMI */ 278, /* (253) trnm ::= nm DOT nm */ 279, /* (254) tridxby ::= INDEXED BY nm */ 279, /* (255) tridxby ::= NOT INDEXED */ 277, /* (256) trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt scanpt */ 277, /* (257) trigger_cmd ::= scanpt insert_cmd INTO trnm idlist_opt select upsert scanpt */ 277, /* (258) trigger_cmd ::= DELETE FROM trnm tridxby where_opt scanpt */ 277, /* (259) trigger_cmd ::= scanpt select scanpt */ 207, /* (260) expr ::= RAISE LP IGNORE RP */ 207, /* (261) expr ::= RAISE LP raisetype COMMA nm RP */ 225, /* (262) raisetype ::= ROLLBACK */ 225, /* (263) raisetype ::= ABORT */ 225, /* (264) raisetype ::= FAIL */ 181, /* (265) cmd ::= DROP TRIGGER ifexists fullname */ 181, /* (266) cmd ::= ATTACH database_kw_opt expr AS expr key_opt */ 181, /* (267) cmd ::= DETACH database_kw_opt expr */ 281, /* (268) key_opt ::= */ 281, /* (269) key_opt ::= KEY expr */ 181, /* (270) cmd ::= REINDEX */ 181, /* (271) cmd ::= REINDEX nm dbnm */ 181, /* (272) cmd ::= ANALYZE */ 181, /* (273) cmd ::= ANALYZE nm dbnm */ 181, /* (274) cmd ::= ALTER TABLE fullname RENAME TO nm */ 181, /* (275) cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt columnname carglist */ 282, /* (276) add_column_fullname ::= fullname */ 181, /* (277) cmd ::= ALTER TABLE fullname RENAME kwcolumn_opt nm TO nm */ 181, /* (278) cmd ::= create_vtab */ 181, /* (279) cmd ::= create_vtab LP vtabarglist RP */ 284, /* (280) create_vtab ::= createkw VIRTUAL TABLE ifnotexists nm dbnm USING nm */ 286, /* (281) vtabarg ::= */ 287, /* (282) vtabargtoken ::= ANY */ 287, /* (283) vtabargtoken ::= lp anylist RP */ 288, /* (284) lp ::= LP */ 254, /* (285) with ::= WITH wqlist */ 254, /* (286) with ::= WITH RECURSIVE wqlist */ 230, /* (287) wqlist ::= nm eidlist_opt AS LP select RP */ 230, /* (288) wqlist ::= wqlist COMMA nm eidlist_opt AS LP select RP */ 290, /* (289) windowdefn_list ::= windowdefn */ 290, /* (290) windowdefn_list ::= windowdefn_list COMMA windowdefn */ 291, /* (291) windowdefn ::= nm AS LP window RP */ 292, /* (292) window ::= PARTITION BY nexprlist orderby_opt frame_opt */ 292, /* (293) window ::= nm PARTITION BY nexprlist orderby_opt frame_opt */ 292, /* (294) window ::= ORDER BY sortlist frame_opt */ 292, /* (295) window ::= nm ORDER BY sortlist frame_opt */ 292, /* (296) window ::= frame_opt */ 292, /* (297) window ::= nm frame_opt */ 293, /* (298) frame_opt ::= */ 293, /* (299) frame_opt ::= range_or_rows frame_bound_s frame_exclude_opt */ 293, /* (300) frame_opt ::= range_or_rows BETWEEN frame_bound_s AND frame_bound_e frame_exclude_opt */ 296, /* (301) range_or_rows ::= RANGE|ROWS|GROUPS */ 298, /* (302) frame_bound_s ::= frame_bound */ 298, /* (303) frame_bound_s ::= UNBOUNDED PRECEDING */ 299, /* (304) frame_bound_e ::= frame_bound */ 299, /* (305) frame_bound_e ::= UNBOUNDED FOLLOWING */ 297, /* (306) frame_bound ::= expr PRECEDING|FOLLOWING */ 297, /* (307) frame_bound ::= CURRENT ROW */ 300, /* (308) frame_exclude_opt ::= */ 300, /* (309) frame_exclude_opt ::= EXCLUDE frame_exclude */ 301, /* (310) frame_exclude ::= NO OTHERS */ 301, /* (311) frame_exclude ::= CURRENT ROW */ 301, /* (312) frame_exclude ::= GROUP|TIES */ 240, /* (313) window_clause ::= WINDOW windowdefn_list */ 259, /* (314) over_clause ::= filter_opt OVER LP window RP */ 259, /* (315) over_clause ::= filter_opt OVER nm */ 295, /* (316) filter_opt ::= */ 295, /* (317) filter_opt ::= FILTER LP WHERE expr RP */ 176, /* (318) input ::= cmdlist */ 177, /* (319) cmdlist ::= cmdlist ecmd */ 177, /* (320) cmdlist ::= ecmd */ 178, /* (321) ecmd ::= SEMI */ 178, /* (322) ecmd ::= cmdx SEMI */ 178, /* (323) ecmd ::= explain cmdx */ 183, /* (324) trans_opt ::= */ 183, /* (325) trans_opt ::= TRANSACTION */ 183, /* (326) trans_opt ::= TRANSACTION nm */ 185, /* (327) savepoint_opt ::= SAVEPOINT */ 185, /* (328) savepoint_opt ::= */ 181, /* (329) cmd ::= create_table create_table_args */ 192, /* (330) columnlist ::= columnlist COMMA columnname carglist */ 192, /* (331) columnlist ::= columnname carglist */ 184, /* (332) nm ::= ID|INDEXED */ 184, /* (333) nm ::= STRING */ 184, /* (334) nm ::= JOIN_KW */ 198, /* (335) typetoken ::= typename */ 199, /* (336) typename ::= ID|STRING */ 200, /* (337) signed ::= plus_num */ 200, /* (338) signed ::= minus_num */ 197, /* (339) carglist ::= carglist ccons */ 197, /* (340) carglist ::= */ 205, /* (341) ccons ::= NULL onconf */ 193, /* (342) conslist_opt ::= COMMA conslist */ 217, /* (343) conslist ::= conslist tconscomma tcons */ 217, /* (344) conslist ::= tcons */ 218, /* (345) tconscomma ::= */ 222, /* (346) defer_subclause_opt ::= defer_subclause */ 224, /* (347) resolvetype ::= raisetype */ 228, /* (348) selectnowith ::= oneselect */ 229, /* (349) oneselect ::= values */ 243, /* (350) sclp ::= selcollist COMMA */ 244, /* (351) as ::= ID|STRING */ 207, /* (352) expr ::= term */ 260, /* (353) likeop ::= LIKE_KW|MATCH */ 251, /* (354) exprlist ::= nexprlist */ 270, /* (355) nmnum ::= plus_num */ 270, /* (356) nmnum ::= nm */ 270, /* (357) nmnum ::= ON */ 270, /* (358) nmnum ::= DELETE */ 270, /* (359) nmnum ::= DEFAULT */ 201, /* (360) plus_num ::= INTEGER|FLOAT */ 275, /* (361) foreach_clause ::= */ 275, /* (362) foreach_clause ::= FOR EACH ROW */ 278, /* (363) trnm ::= nm */ 279, /* (364) tridxby ::= */ 280, /* (365) database_kw_opt ::= DATABASE */ 280, /* (366) database_kw_opt ::= */ 283, /* (367) kwcolumn_opt ::= */ 283, /* (368) kwcolumn_opt ::= COLUMNKW */ 285, /* (369) vtabarglist ::= vtabarg */ 285, /* (370) vtabarglist ::= vtabarglist COMMA vtabarg */ 286, /* (371) vtabarg ::= vtabarg vtabargtoken */ 289, /* (372) anylist ::= */ 289, /* (373) anylist ::= anylist LP anylist RP */ 289, /* (374) anylist ::= anylist ANY */ 254, /* (375) with ::= */ }; /* For rule J, yyRuleInfoNRhs[J] contains the negative of the number ** of symbols on the right-hand side of that rule. */ static const signed char yyRuleInfoNRhs[] = { -1, /* (0) explain ::= EXPLAIN */ -3, /* (1) explain ::= EXPLAIN QUERY PLAN */ |
︙ | ︙ | |||
151162 151163 151164 151165 151166 151167 151168 | -2, /* (22) table_options ::= WITHOUT nm */ -2, /* (23) columnname ::= nm typetoken */ 0, /* (24) typetoken ::= */ -4, /* (25) typetoken ::= typename LP signed RP */ -6, /* (26) typetoken ::= typename LP signed COMMA signed RP */ -2, /* (27) typename ::= typename ID|STRING */ 0, /* (28) scanpt ::= */ | | | | | | | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | | | | | | | > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < | > | | | | | | | | | | | | | | | | | | | | < | | > | | | | | | | | | | | | | | | | | | | | < | | | | > | | | | | | | | | | | | | | | | | 151312 151313 151314 151315 151316 151317 151318 151319 151320 151321 151322 151323 151324 151325 151326 151327 151328 151329 151330 151331 151332 151333 151334 151335 151336 151337 151338 151339 151340 151341 151342 151343 151344 151345 151346 151347 151348 151349 151350 151351 151352 151353 151354 151355 151356 151357 151358 151359 151360 151361 151362 151363 151364 151365 151366 151367 151368 151369 151370 151371 151372 151373 151374 151375 151376 151377 151378 151379 151380 151381 151382 151383 151384 151385 151386 151387 151388 151389 151390 151391 151392 151393 151394 151395 151396 151397 151398 151399 151400 151401 151402 151403 151404 151405 151406 151407 151408 151409 151410 151411 151412 151413 151414 151415 151416 151417 151418 151419 151420 151421 151422 151423 151424 151425 151426 151427 151428 151429 151430 151431 151432 151433 151434 151435 151436 151437 151438 151439 151440 151441 151442 151443 151444 151445 151446 151447 151448 151449 151450 151451 151452 151453 151454 151455 151456 151457 151458 151459 151460 151461 151462 151463 151464 151465 151466 151467 151468 151469 151470 151471 151472 151473 151474 151475 151476 151477 151478 151479 151480 151481 151482 151483 151484 151485 151486 151487 151488 151489 151490 151491 151492 151493 151494 151495 151496 151497 151498 151499 151500 151501 151502 151503 151504 151505 151506 151507 151508 151509 151510 151511 151512 151513 151514 151515 151516 151517 151518 151519 151520 151521 151522 151523 151524 151525 151526 151527 151528 151529 151530 151531 151532 151533 151534 151535 151536 151537 151538 151539 151540 151541 151542 151543 151544 151545 151546 151547 151548 151549 151550 151551 151552 151553 151554 151555 151556 151557 151558 151559 151560 151561 151562 151563 151564 151565 151566 151567 151568 151569 151570 151571 151572 151573 151574 151575 151576 151577 151578 151579 151580 151581 151582 151583 151584 151585 151586 151587 151588 151589 151590 151591 151592 151593 151594 151595 151596 151597 151598 151599 151600 151601 151602 151603 151604 151605 151606 151607 151608 151609 151610 151611 151612 151613 151614 151615 151616 151617 151618 151619 151620 151621 151622 151623 151624 151625 151626 151627 151628 151629 151630 151631 151632 151633 151634 151635 151636 151637 151638 151639 151640 151641 151642 151643 151644 151645 151646 151647 151648 151649 151650 151651 151652 151653 151654 151655 151656 151657 151658 151659 151660 151661 151662 151663 151664 151665 151666 151667 151668 151669 151670 151671 151672 | -2, /* (22) table_options ::= WITHOUT nm */ -2, /* (23) columnname ::= nm typetoken */ 0, /* (24) typetoken ::= */ -4, /* (25) typetoken ::= typename LP signed RP */ -6, /* (26) typetoken ::= typename LP signed COMMA signed RP */ -2, /* (27) typename ::= typename ID|STRING */ 0, /* (28) scanpt ::= */ 0, /* (29) scantok ::= */ -2, /* (30) ccons ::= CONSTRAINT nm */ -3, /* (31) ccons ::= DEFAULT scantok term */ -4, /* (32) ccons ::= DEFAULT LP expr RP */ -4, /* (33) ccons ::= DEFAULT PLUS scantok term */ -4, /* (34) ccons ::= DEFAULT MINUS scantok term */ -3, /* (35) ccons ::= DEFAULT scantok ID|INDEXED */ -3, /* (36) ccons ::= NOT NULL onconf */ -5, /* (37) ccons ::= PRIMARY KEY sortorder onconf autoinc */ -2, /* (38) ccons ::= UNIQUE onconf */ -4, /* (39) ccons ::= CHECK LP expr RP */ -4, /* (40) ccons ::= REFERENCES nm eidlist_opt refargs */ -1, /* (41) ccons ::= defer_subclause */ -2, /* (42) ccons ::= COLLATE ID|STRING */ 0, /* (43) autoinc ::= */ -1, /* (44) autoinc ::= AUTOINCR */ 0, /* (45) refargs ::= */ -2, /* (46) refargs ::= refargs refarg */ -2, /* (47) refarg ::= MATCH nm */ -3, /* (48) refarg ::= ON INSERT refact */ -3, /* (49) refarg ::= ON DELETE refact */ -3, /* (50) refarg ::= ON UPDATE refact */ -2, /* (51) refact ::= SET NULL */ -2, /* (52) refact ::= SET DEFAULT */ -1, /* (53) refact ::= CASCADE */ -1, /* (54) refact ::= RESTRICT */ -2, /* (55) refact ::= NO ACTION */ -3, /* (56) defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt */ -2, /* (57) defer_subclause ::= DEFERRABLE init_deferred_pred_opt */ 0, /* (58) init_deferred_pred_opt ::= */ -2, /* (59) init_deferred_pred_opt ::= INITIALLY DEFERRED */ -2, /* (60) init_deferred_pred_opt ::= INITIALLY IMMEDIATE */ 0, /* (61) conslist_opt ::= */ -1, /* (62) tconscomma ::= COMMA */ -2, /* (63) tcons ::= CONSTRAINT nm */ -7, /* (64) tcons ::= PRIMARY KEY LP sortlist autoinc RP onconf */ -5, /* (65) tcons ::= UNIQUE LP sortlist RP onconf */ -5, /* (66) tcons ::= CHECK LP expr RP onconf */ -10, /* (67) tcons ::= FOREIGN KEY LP eidlist RP REFERENCES nm eidlist_opt refargs defer_subclause_opt */ 0, /* (68) defer_subclause_opt ::= */ 0, /* (69) onconf ::= */ -3, /* (70) onconf ::= ON CONFLICT resolvetype */ 0, /* (71) orconf ::= */ -2, /* (72) orconf ::= OR resolvetype */ -1, /* (73) resolvetype ::= IGNORE */ -1, /* (74) resolvetype ::= REPLACE */ -4, /* (75) cmd ::= DROP TABLE ifexists fullname */ -2, /* (76) ifexists ::= IF EXISTS */ 0, /* (77) ifexists ::= */ -9, /* (78) cmd ::= createkw temp VIEW ifnotexists nm dbnm eidlist_opt AS select */ -4, /* (79) cmd ::= DROP VIEW ifexists fullname */ -1, /* (80) cmd ::= select */ -3, /* (81) select ::= WITH wqlist selectnowith */ -4, /* (82) select ::= WITH RECURSIVE wqlist selectnowith */ -1, /* (83) select ::= selectnowith */ -3, /* (84) selectnowith ::= selectnowith multiselect_op oneselect */ -1, /* (85) multiselect_op ::= UNION */ -2, /* (86) multiselect_op ::= UNION ALL */ -1, /* (87) multiselect_op ::= EXCEPT|INTERSECT */ -9, /* (88) oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt orderby_opt limit_opt */ -10, /* (89) oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt window_clause orderby_opt limit_opt */ -4, /* (90) values ::= VALUES LP nexprlist RP */ -5, /* (91) values ::= values COMMA LP nexprlist RP */ -1, /* (92) distinct ::= DISTINCT */ -1, /* (93) distinct ::= ALL */ 0, /* (94) distinct ::= */ 0, /* (95) sclp ::= */ -5, /* (96) selcollist ::= sclp scanpt expr scanpt as */ -3, /* (97) selcollist ::= sclp scanpt STAR */ -5, /* (98) selcollist ::= sclp scanpt nm DOT STAR */ -2, /* (99) as ::= AS nm */ 0, /* (100) as ::= */ 0, /* (101) from ::= */ -2, /* (102) from ::= FROM seltablist */ -2, /* (103) stl_prefix ::= seltablist joinop */ 0, /* (104) stl_prefix ::= */ -7, /* (105) seltablist ::= stl_prefix nm dbnm as indexed_opt on_opt using_opt */ -9, /* (106) seltablist ::= stl_prefix nm dbnm LP exprlist RP as on_opt using_opt */ -7, /* (107) seltablist ::= stl_prefix LP select RP as on_opt using_opt */ -7, /* (108) seltablist ::= stl_prefix LP seltablist RP as on_opt using_opt */ 0, /* (109) dbnm ::= */ -2, /* (110) dbnm ::= DOT nm */ -1, /* (111) fullname ::= nm */ -3, /* (112) fullname ::= nm DOT nm */ -1, /* (113) xfullname ::= nm */ -3, /* (114) xfullname ::= nm DOT nm */ -5, /* (115) xfullname ::= nm DOT nm AS nm */ -3, /* (116) xfullname ::= nm AS nm */ -1, /* (117) joinop ::= COMMA|JOIN */ -2, /* (118) joinop ::= JOIN_KW JOIN */ -3, /* (119) joinop ::= JOIN_KW nm JOIN */ -4, /* (120) joinop ::= JOIN_KW nm nm JOIN */ -2, /* (121) on_opt ::= ON expr */ 0, /* (122) on_opt ::= */ 0, /* (123) indexed_opt ::= */ -3, /* (124) indexed_opt ::= INDEXED BY nm */ -2, /* (125) indexed_opt ::= NOT INDEXED */ -4, /* (126) using_opt ::= USING LP idlist RP */ 0, /* (127) using_opt ::= */ 0, /* (128) orderby_opt ::= */ -3, /* (129) orderby_opt ::= ORDER BY sortlist */ -4, /* (130) sortlist ::= sortlist COMMA expr sortorder */ -2, /* (131) sortlist ::= expr sortorder */ -1, /* (132) sortorder ::= ASC */ -1, /* (133) sortorder ::= DESC */ 0, /* (134) sortorder ::= */ 0, /* (135) groupby_opt ::= */ -3, /* (136) groupby_opt ::= GROUP BY nexprlist */ 0, /* (137) having_opt ::= */ -2, /* (138) having_opt ::= HAVING expr */ 0, /* (139) limit_opt ::= */ -2, /* (140) limit_opt ::= LIMIT expr */ -4, /* (141) limit_opt ::= LIMIT expr OFFSET expr */ -4, /* (142) limit_opt ::= LIMIT expr COMMA expr */ -6, /* (143) cmd ::= with DELETE FROM xfullname indexed_opt where_opt */ 0, /* (144) where_opt ::= */ -2, /* (145) where_opt ::= WHERE expr */ -8, /* (146) cmd ::= with UPDATE orconf xfullname indexed_opt SET setlist where_opt */ -5, /* (147) setlist ::= setlist COMMA nm EQ expr */ -7, /* (148) setlist ::= setlist COMMA LP idlist RP EQ expr */ -3, /* (149) setlist ::= nm EQ expr */ -5, /* (150) setlist ::= LP idlist RP EQ expr */ -7, /* (151) cmd ::= with insert_cmd INTO xfullname idlist_opt select upsert */ -7, /* (152) cmd ::= with insert_cmd INTO xfullname idlist_opt DEFAULT VALUES */ 0, /* (153) upsert ::= */ -11, /* (154) upsert ::= ON CONFLICT LP sortlist RP where_opt DO UPDATE SET setlist where_opt */ -8, /* (155) upsert ::= ON CONFLICT LP sortlist RP where_opt DO NOTHING */ -4, /* (156) upsert ::= ON CONFLICT DO NOTHING */ -2, /* (157) insert_cmd ::= INSERT orconf */ -1, /* (158) insert_cmd ::= REPLACE */ 0, /* (159) idlist_opt ::= */ -3, /* (160) idlist_opt ::= LP idlist RP */ -3, /* (161) idlist ::= idlist COMMA nm */ -1, /* (162) idlist ::= nm */ -3, /* (163) expr ::= LP expr RP */ -1, /* (164) expr ::= ID|INDEXED */ -1, /* (165) expr ::= JOIN_KW */ -3, /* (166) expr ::= nm DOT nm */ -5, /* (167) expr ::= nm DOT nm DOT nm */ -1, /* (168) term ::= NULL|FLOAT|BLOB */ -1, /* (169) term ::= STRING */ -1, /* (170) term ::= INTEGER */ -1, /* (171) expr ::= VARIABLE */ -3, /* (172) expr ::= expr COLLATE ID|STRING */ -6, /* (173) expr ::= CAST LP expr AS typetoken RP */ -5, /* (174) expr ::= ID|INDEXED LP distinct exprlist RP */ -4, /* (175) expr ::= ID|INDEXED LP STAR RP */ -6, /* (176) expr ::= ID|INDEXED LP distinct exprlist RP over_clause */ -5, /* (177) expr ::= ID|INDEXED LP STAR RP over_clause */ -1, /* (178) term ::= CTIME_KW */ -5, /* (179) expr ::= LP nexprlist COMMA expr RP */ -3, /* (180) expr ::= expr AND expr */ -3, /* (181) expr ::= expr OR expr */ -3, /* (182) expr ::= expr LT|GT|GE|LE expr */ -3, /* (183) expr ::= expr EQ|NE expr */ -3, /* (184) expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr */ -3, /* (185) expr ::= expr PLUS|MINUS expr */ -3, /* (186) expr ::= expr STAR|SLASH|REM expr */ -3, /* (187) expr ::= expr CONCAT expr */ -2, /* (188) likeop ::= NOT LIKE_KW|MATCH */ -3, /* (189) expr ::= expr likeop expr */ -5, /* (190) expr ::= expr likeop expr ESCAPE expr */ -2, /* (191) expr ::= expr ISNULL|NOTNULL */ -3, /* (192) expr ::= expr NOT NULL */ -3, /* (193) expr ::= expr IS expr */ -4, /* (194) expr ::= expr IS NOT expr */ -2, /* (195) expr ::= NOT expr */ -2, /* (196) expr ::= BITNOT expr */ -2, /* (197) expr ::= PLUS|MINUS expr */ -1, /* (198) between_op ::= BETWEEN */ -2, /* (199) between_op ::= NOT BETWEEN */ -5, /* (200) expr ::= expr between_op expr AND expr */ -1, /* (201) in_op ::= IN */ -2, /* (202) in_op ::= NOT IN */ -5, /* (203) expr ::= expr in_op LP exprlist RP */ -3, /* (204) expr ::= LP select RP */ -5, /* (205) expr ::= expr in_op LP select RP */ -5, /* (206) expr ::= expr in_op nm dbnm paren_exprlist */ -4, /* (207) expr ::= EXISTS LP select RP */ -5, /* (208) expr ::= CASE case_operand case_exprlist case_else END */ -5, /* (209) case_exprlist ::= case_exprlist WHEN expr THEN expr */ -4, /* (210) case_exprlist ::= WHEN expr THEN expr */ -2, /* (211) case_else ::= ELSE expr */ 0, /* (212) case_else ::= */ -1, /* (213) case_operand ::= expr */ 0, /* (214) case_operand ::= */ 0, /* (215) exprlist ::= */ -3, /* (216) nexprlist ::= nexprlist COMMA expr */ -1, /* (217) nexprlist ::= expr */ 0, /* (218) paren_exprlist ::= */ -3, /* (219) paren_exprlist ::= LP exprlist RP */ -12, /* (220) cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP sortlist RP where_opt */ -1, /* (221) uniqueflag ::= UNIQUE */ 0, /* (222) uniqueflag ::= */ 0, /* (223) eidlist_opt ::= */ -3, /* (224) eidlist_opt ::= LP eidlist RP */ -5, /* (225) eidlist ::= eidlist COMMA nm collate sortorder */ -3, /* (226) eidlist ::= nm collate sortorder */ 0, /* (227) collate ::= */ -2, /* (228) collate ::= COLLATE ID|STRING */ -4, /* (229) cmd ::= DROP INDEX ifexists fullname */ -2, /* (230) cmd ::= VACUUM vinto */ -3, /* (231) cmd ::= VACUUM nm vinto */ -2, /* (232) vinto ::= INTO expr */ 0, /* (233) vinto ::= */ -3, /* (234) cmd ::= PRAGMA nm dbnm */ -5, /* (235) cmd ::= PRAGMA nm dbnm EQ nmnum */ -6, /* (236) cmd ::= PRAGMA nm dbnm LP nmnum RP */ -5, /* (237) cmd ::= PRAGMA nm dbnm EQ minus_num */ -6, /* (238) cmd ::= PRAGMA nm dbnm LP minus_num RP */ -2, /* (239) plus_num ::= PLUS INTEGER|FLOAT */ -2, /* (240) minus_num ::= MINUS INTEGER|FLOAT */ -5, /* (241) cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END */ -11, /* (242) trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause */ -1, /* (243) trigger_time ::= BEFORE|AFTER */ -2, /* (244) trigger_time ::= INSTEAD OF */ 0, /* (245) trigger_time ::= */ -1, /* (246) trigger_event ::= DELETE|INSERT */ -1, /* (247) trigger_event ::= UPDATE */ -3, /* (248) trigger_event ::= UPDATE OF idlist */ 0, /* (249) when_clause ::= */ -2, /* (250) when_clause ::= WHEN expr */ -3, /* (251) trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI */ -2, /* (252) trigger_cmd_list ::= trigger_cmd SEMI */ -3, /* (253) trnm ::= nm DOT nm */ -3, /* (254) tridxby ::= INDEXED BY nm */ -2, /* (255) tridxby ::= NOT INDEXED */ -8, /* (256) trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt scanpt */ -8, /* (257) trigger_cmd ::= scanpt insert_cmd INTO trnm idlist_opt select upsert scanpt */ -6, /* (258) trigger_cmd ::= DELETE FROM trnm tridxby where_opt scanpt */ -3, /* (259) trigger_cmd ::= scanpt select scanpt */ -4, /* (260) expr ::= RAISE LP IGNORE RP */ -6, /* (261) expr ::= RAISE LP raisetype COMMA nm RP */ -1, /* (262) raisetype ::= ROLLBACK */ -1, /* (263) raisetype ::= ABORT */ -1, /* (264) raisetype ::= FAIL */ -4, /* (265) cmd ::= DROP TRIGGER ifexists fullname */ -6, /* (266) cmd ::= ATTACH database_kw_opt expr AS expr key_opt */ -3, /* (267) cmd ::= DETACH database_kw_opt expr */ 0, /* (268) key_opt ::= */ -2, /* (269) key_opt ::= KEY expr */ -1, /* (270) cmd ::= REINDEX */ -3, /* (271) cmd ::= REINDEX nm dbnm */ -1, /* (272) cmd ::= ANALYZE */ -3, /* (273) cmd ::= ANALYZE nm dbnm */ -6, /* (274) cmd ::= ALTER TABLE fullname RENAME TO nm */ -7, /* (275) cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt columnname carglist */ -1, /* (276) add_column_fullname ::= fullname */ -8, /* (277) cmd ::= ALTER TABLE fullname RENAME kwcolumn_opt nm TO nm */ -1, /* (278) cmd ::= create_vtab */ -4, /* (279) cmd ::= create_vtab LP vtabarglist RP */ -8, /* (280) create_vtab ::= createkw VIRTUAL TABLE ifnotexists nm dbnm USING nm */ 0, /* (281) vtabarg ::= */ -1, /* (282) vtabargtoken ::= ANY */ -3, /* (283) vtabargtoken ::= lp anylist RP */ -1, /* (284) lp ::= LP */ -2, /* (285) with ::= WITH wqlist */ -3, /* (286) with ::= WITH RECURSIVE wqlist */ -6, /* (287) wqlist ::= nm eidlist_opt AS LP select RP */ -8, /* (288) wqlist ::= wqlist COMMA nm eidlist_opt AS LP select RP */ -1, /* (289) windowdefn_list ::= windowdefn */ -3, /* (290) windowdefn_list ::= windowdefn_list COMMA windowdefn */ -5, /* (291) windowdefn ::= nm AS LP window RP */ -5, /* (292) window ::= PARTITION BY nexprlist orderby_opt frame_opt */ -6, /* (293) window ::= nm PARTITION BY nexprlist orderby_opt frame_opt */ -4, /* (294) window ::= ORDER BY sortlist frame_opt */ -5, /* (295) window ::= nm ORDER BY sortlist frame_opt */ -1, /* (296) window ::= frame_opt */ -2, /* (297) window ::= nm frame_opt */ 0, /* (298) frame_opt ::= */ -3, /* (299) frame_opt ::= range_or_rows frame_bound_s frame_exclude_opt */ -6, /* (300) frame_opt ::= range_or_rows BETWEEN frame_bound_s AND frame_bound_e frame_exclude_opt */ -1, /* (301) range_or_rows ::= RANGE|ROWS|GROUPS */ -1, /* (302) frame_bound_s ::= frame_bound */ -2, /* (303) frame_bound_s ::= UNBOUNDED PRECEDING */ -1, /* (304) frame_bound_e ::= frame_bound */ -2, /* (305) frame_bound_e ::= UNBOUNDED FOLLOWING */ -2, /* (306) frame_bound ::= expr PRECEDING|FOLLOWING */ -2, /* (307) frame_bound ::= CURRENT ROW */ 0, /* (308) frame_exclude_opt ::= */ -2, /* (309) frame_exclude_opt ::= EXCLUDE frame_exclude */ -2, /* (310) frame_exclude ::= NO OTHERS */ -2, /* (311) frame_exclude ::= CURRENT ROW */ -1, /* (312) frame_exclude ::= GROUP|TIES */ -2, /* (313) window_clause ::= WINDOW windowdefn_list */ -5, /* (314) over_clause ::= filter_opt OVER LP window RP */ -3, /* (315) over_clause ::= filter_opt OVER nm */ 0, /* (316) filter_opt ::= */ -5, /* (317) filter_opt ::= FILTER LP WHERE expr RP */ -1, /* (318) input ::= cmdlist */ -2, /* (319) cmdlist ::= cmdlist ecmd */ -1, /* (320) cmdlist ::= ecmd */ -1, /* (321) ecmd ::= SEMI */ -2, /* (322) ecmd ::= cmdx SEMI */ -2, /* (323) ecmd ::= explain cmdx */ 0, /* (324) trans_opt ::= */ -1, /* (325) trans_opt ::= TRANSACTION */ -2, /* (326) trans_opt ::= TRANSACTION nm */ -1, /* (327) savepoint_opt ::= SAVEPOINT */ 0, /* (328) savepoint_opt ::= */ -2, /* (329) cmd ::= create_table create_table_args */ -4, /* (330) columnlist ::= columnlist COMMA columnname carglist */ -2, /* (331) columnlist ::= columnname carglist */ -1, /* (332) nm ::= ID|INDEXED */ -1, /* (333) nm ::= STRING */ -1, /* (334) nm ::= JOIN_KW */ -1, /* (335) typetoken ::= typename */ -1, /* (336) typename ::= ID|STRING */ -1, /* (337) signed ::= plus_num */ -1, /* (338) signed ::= minus_num */ -2, /* (339) carglist ::= carglist ccons */ 0, /* (340) carglist ::= */ -2, /* (341) ccons ::= NULL onconf */ -2, /* (342) conslist_opt ::= COMMA conslist */ -3, /* (343) conslist ::= conslist tconscomma tcons */ -1, /* (344) conslist ::= tcons */ 0, /* (345) tconscomma ::= */ -1, /* (346) defer_subclause_opt ::= defer_subclause */ -1, /* (347) resolvetype ::= raisetype */ -1, /* (348) selectnowith ::= oneselect */ -1, /* (349) oneselect ::= values */ -2, /* (350) sclp ::= selcollist COMMA */ -1, /* (351) as ::= ID|STRING */ -1, /* (352) expr ::= term */ -1, /* (353) likeop ::= LIKE_KW|MATCH */ -1, /* (354) exprlist ::= nexprlist */ -1, /* (355) nmnum ::= plus_num */ -1, /* (356) nmnum ::= nm */ -1, /* (357) nmnum ::= ON */ -1, /* (358) nmnum ::= DELETE */ -1, /* (359) nmnum ::= DEFAULT */ -1, /* (360) plus_num ::= INTEGER|FLOAT */ 0, /* (361) foreach_clause ::= */ -3, /* (362) foreach_clause ::= FOR EACH ROW */ -1, /* (363) trnm ::= nm */ 0, /* (364) tridxby ::= */ -1, /* (365) database_kw_opt ::= DATABASE */ 0, /* (366) database_kw_opt ::= */ 0, /* (367) kwcolumn_opt ::= */ -1, /* (368) kwcolumn_opt ::= COLUMNKW */ -1, /* (369) vtabarglist ::= vtabarg */ -3, /* (370) vtabarglist ::= vtabarglist COMMA vtabarg */ -2, /* (371) vtabarg ::= vtabarg vtabargtoken */ 0, /* (372) anylist ::= */ -4, /* (373) anylist ::= anylist LP anylist RP */ -2, /* (374) anylist ::= anylist ANY */ 0, /* (375) with ::= */ }; static void yy_accept(yyParser*); /* Forward Declaration */ /* ** Perform a reduce action and the shift that must immediately ** follow the reduce. |
︙ | ︙ | |||
151604 151605 151606 151607 151608 151609 151610 | case 1: /* explain ::= EXPLAIN QUERY PLAN */ { pParse->explain = 2; } break; case 2: /* cmdx ::= cmd */ { sqlite3FinishCoding(pParse); } break; case 3: /* cmd ::= BEGIN transtype trans_opt */ | | | | | | 151755 151756 151757 151758 151759 151760 151761 151762 151763 151764 151765 151766 151767 151768 151769 151770 151771 151772 151773 151774 151775 151776 151777 151778 | case 1: /* explain ::= EXPLAIN QUERY PLAN */ { pParse->explain = 2; } break; case 2: /* cmdx ::= cmd */ { sqlite3FinishCoding(pParse); } break; case 3: /* cmd ::= BEGIN transtype trans_opt */ {sqlite3BeginTransaction(pParse, yymsp[-1].minor.yy100);} break; case 4: /* transtype ::= */ {yymsp[1].minor.yy100 = TK_DEFERRED;} break; case 5: /* transtype ::= DEFERRED */ case 6: /* transtype ::= IMMEDIATE */ yytestcase(yyruleno==6); case 7: /* transtype ::= EXCLUSIVE */ yytestcase(yyruleno==7); case 301: /* range_or_rows ::= RANGE|ROWS|GROUPS */ yytestcase(yyruleno==301); {yymsp[0].minor.yy100 = yymsp[0].major; /*A-overwrites-X*/} break; case 8: /* cmd ::= COMMIT|END trans_opt */ case 9: /* cmd ::= ROLLBACK trans_opt */ yytestcase(yyruleno==9); {sqlite3EndTransaction(pParse,yymsp[-1].major);} break; case 10: /* cmd ::= SAVEPOINT nm */ { |
︙ | ︙ | |||
151636 151637 151638 151639 151640 151641 151642 | case 12: /* cmd ::= ROLLBACK trans_opt TO savepoint_opt nm */ { sqlite3Savepoint(pParse, SAVEPOINT_ROLLBACK, &yymsp[0].minor.yy0); } break; case 13: /* create_table ::= createkw temp TABLE ifnotexists nm dbnm */ { | | | | | | | | | | | | | | | | | | | | > > > > > > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | < < < < < < < > > > > > > > | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 151787 151788 151789 151790 151791 151792 151793 151794 151795 151796 151797 151798 151799 151800 151801 151802 151803 151804 151805 151806 151807 151808 151809 151810 151811 151812 151813 151814 151815 151816 151817 151818 151819 151820 151821 151822 151823 151824 151825 151826 151827 151828 151829 151830 151831 151832 151833 151834 151835 151836 151837 151838 151839 151840 151841 151842 151843 151844 151845 151846 151847 151848 151849 151850 151851 151852 151853 151854 151855 151856 151857 151858 151859 151860 151861 151862 151863 151864 151865 151866 151867 151868 151869 151870 151871 151872 151873 151874 151875 151876 151877 151878 151879 151880 151881 151882 151883 151884 151885 151886 151887 151888 151889 151890 151891 151892 151893 151894 151895 151896 151897 151898 151899 151900 151901 151902 151903 151904 151905 151906 151907 151908 151909 151910 151911 151912 151913 151914 151915 151916 151917 151918 151919 151920 151921 151922 151923 151924 151925 151926 151927 151928 151929 151930 151931 151932 151933 151934 151935 151936 151937 151938 151939 151940 151941 151942 151943 151944 151945 151946 151947 151948 151949 151950 151951 151952 151953 151954 151955 151956 151957 151958 151959 151960 151961 151962 151963 151964 151965 151966 151967 151968 151969 151970 151971 151972 151973 151974 151975 151976 151977 151978 151979 151980 151981 151982 151983 151984 151985 151986 151987 151988 151989 151990 151991 151992 151993 151994 151995 151996 151997 151998 151999 152000 152001 152002 152003 152004 152005 152006 152007 152008 152009 152010 152011 152012 152013 152014 152015 152016 152017 152018 152019 152020 152021 152022 152023 152024 152025 152026 152027 152028 152029 152030 152031 152032 152033 152034 152035 152036 152037 152038 152039 152040 152041 152042 152043 152044 152045 152046 152047 152048 152049 152050 152051 152052 152053 152054 152055 152056 152057 152058 152059 152060 152061 152062 152063 152064 152065 152066 152067 152068 152069 152070 152071 152072 152073 152074 152075 152076 152077 152078 152079 152080 152081 152082 152083 152084 152085 152086 152087 152088 152089 152090 152091 152092 152093 152094 152095 152096 152097 152098 152099 152100 152101 152102 152103 152104 152105 152106 152107 152108 152109 152110 152111 152112 152113 152114 152115 152116 152117 152118 152119 152120 152121 152122 152123 152124 152125 152126 152127 152128 152129 152130 152131 152132 152133 152134 152135 152136 152137 152138 152139 152140 152141 152142 152143 152144 152145 152146 152147 152148 152149 152150 152151 152152 152153 152154 152155 152156 152157 152158 152159 152160 152161 152162 152163 152164 152165 152166 152167 152168 152169 152170 152171 152172 152173 152174 152175 152176 152177 152178 152179 152180 152181 152182 152183 152184 152185 152186 152187 152188 152189 152190 152191 152192 152193 152194 152195 152196 152197 152198 152199 152200 152201 152202 152203 152204 152205 152206 152207 152208 152209 152210 152211 152212 152213 152214 152215 152216 152217 152218 152219 152220 152221 152222 152223 152224 152225 152226 152227 152228 152229 152230 152231 152232 152233 152234 152235 152236 152237 152238 152239 152240 152241 152242 152243 152244 152245 152246 152247 152248 152249 152250 152251 152252 152253 152254 152255 152256 152257 152258 152259 152260 152261 152262 152263 152264 152265 152266 152267 152268 152269 152270 152271 152272 152273 152274 152275 152276 152277 152278 152279 152280 152281 152282 152283 152284 152285 152286 152287 152288 152289 152290 152291 152292 152293 152294 152295 152296 152297 152298 152299 152300 152301 152302 152303 152304 152305 152306 152307 152308 152309 152310 152311 152312 152313 152314 152315 152316 152317 152318 152319 152320 152321 152322 152323 152324 152325 152326 152327 152328 152329 152330 152331 152332 152333 152334 152335 152336 152337 152338 152339 152340 152341 152342 152343 152344 152345 152346 152347 152348 152349 152350 152351 152352 152353 152354 152355 152356 152357 152358 152359 152360 152361 152362 152363 152364 152365 152366 152367 152368 152369 152370 152371 152372 152373 152374 152375 152376 152377 152378 152379 152380 152381 152382 152383 152384 152385 152386 152387 152388 152389 152390 152391 152392 152393 152394 152395 152396 152397 152398 152399 152400 152401 152402 152403 152404 152405 152406 152407 152408 152409 152410 152411 152412 152413 152414 152415 152416 152417 152418 152419 152420 152421 152422 152423 152424 152425 152426 152427 152428 152429 152430 152431 152432 152433 152434 152435 152436 152437 152438 152439 152440 152441 152442 152443 152444 152445 152446 152447 152448 152449 152450 152451 152452 152453 152454 152455 152456 152457 152458 152459 152460 152461 152462 152463 152464 152465 152466 152467 152468 152469 152470 152471 152472 152473 152474 152475 152476 152477 152478 152479 152480 152481 152482 152483 152484 152485 152486 152487 152488 152489 152490 152491 152492 152493 152494 152495 152496 152497 152498 152499 152500 152501 152502 152503 152504 152505 152506 152507 152508 152509 152510 152511 152512 152513 152514 152515 152516 152517 152518 152519 152520 152521 152522 152523 152524 152525 152526 152527 152528 152529 152530 152531 152532 152533 152534 152535 152536 152537 152538 152539 152540 152541 152542 152543 152544 152545 152546 152547 152548 152549 152550 152551 152552 152553 152554 152555 152556 152557 152558 152559 152560 152561 152562 152563 152564 152565 152566 152567 152568 152569 152570 152571 152572 152573 152574 152575 152576 152577 152578 152579 152580 152581 152582 152583 152584 152585 152586 152587 152588 152589 152590 152591 152592 152593 152594 152595 152596 152597 152598 152599 152600 152601 152602 152603 152604 152605 152606 152607 152608 152609 152610 152611 152612 152613 152614 152615 152616 152617 152618 152619 152620 152621 152622 152623 152624 152625 152626 152627 152628 152629 152630 152631 152632 152633 152634 152635 152636 152637 152638 152639 152640 152641 152642 152643 152644 152645 152646 152647 152648 152649 152650 152651 152652 152653 152654 152655 152656 152657 152658 152659 152660 152661 152662 152663 152664 152665 152666 152667 152668 152669 152670 152671 152672 152673 152674 152675 152676 152677 152678 152679 152680 152681 152682 152683 152684 152685 152686 152687 152688 152689 152690 152691 152692 152693 152694 152695 152696 152697 152698 152699 152700 152701 152702 152703 152704 152705 152706 152707 152708 152709 152710 152711 152712 152713 152714 152715 152716 152717 152718 152719 152720 152721 152722 152723 152724 152725 152726 152727 152728 152729 152730 152731 152732 152733 152734 152735 152736 152737 152738 152739 152740 152741 152742 152743 152744 152745 152746 152747 152748 152749 152750 152751 152752 152753 152754 152755 152756 152757 152758 152759 152760 152761 152762 152763 152764 152765 152766 152767 152768 152769 152770 152771 152772 152773 152774 152775 152776 152777 152778 152779 152780 152781 152782 152783 152784 152785 152786 152787 152788 152789 152790 152791 152792 152793 152794 152795 152796 152797 152798 152799 152800 152801 152802 152803 152804 152805 152806 152807 152808 152809 152810 152811 152812 152813 152814 152815 152816 152817 152818 152819 152820 152821 152822 152823 152824 152825 152826 152827 152828 152829 152830 152831 152832 152833 152834 152835 152836 152837 152838 152839 152840 152841 152842 152843 152844 152845 152846 152847 152848 152849 152850 152851 152852 152853 152854 152855 152856 152857 152858 152859 152860 152861 152862 152863 152864 152865 152866 152867 152868 152869 152870 152871 152872 152873 152874 152875 152876 152877 152878 152879 152880 152881 152882 152883 152884 152885 152886 152887 152888 152889 152890 152891 152892 152893 152894 152895 152896 152897 152898 152899 152900 152901 152902 152903 152904 152905 152906 152907 152908 152909 152910 152911 152912 152913 152914 152915 152916 152917 152918 152919 152920 152921 152922 152923 152924 152925 152926 152927 152928 152929 152930 152931 152932 152933 152934 152935 152936 152937 152938 152939 152940 152941 152942 152943 152944 152945 152946 152947 152948 152949 152950 152951 152952 152953 152954 152955 152956 152957 152958 152959 152960 152961 152962 152963 152964 152965 152966 152967 152968 152969 152970 152971 152972 152973 152974 152975 152976 152977 152978 152979 152980 152981 152982 152983 152984 152985 152986 152987 152988 152989 152990 152991 152992 152993 152994 152995 152996 152997 152998 152999 153000 153001 153002 153003 153004 153005 153006 153007 153008 153009 153010 153011 153012 153013 153014 153015 153016 153017 153018 153019 153020 153021 153022 153023 153024 153025 153026 153027 153028 153029 153030 153031 153032 153033 153034 153035 153036 153037 153038 153039 153040 153041 153042 153043 153044 153045 153046 153047 153048 153049 153050 153051 153052 153053 153054 153055 153056 153057 153058 153059 153060 153061 153062 153063 153064 153065 153066 153067 153068 153069 153070 153071 153072 153073 153074 153075 153076 153077 153078 153079 153080 153081 153082 153083 153084 153085 153086 153087 153088 153089 153090 153091 153092 153093 153094 153095 153096 153097 153098 153099 153100 153101 153102 153103 153104 153105 153106 153107 153108 153109 153110 153111 153112 153113 153114 153115 153116 153117 153118 153119 153120 153121 153122 153123 153124 153125 153126 153127 153128 153129 153130 153131 153132 153133 153134 153135 153136 153137 153138 153139 153140 153141 153142 153143 153144 153145 153146 153147 153148 153149 153150 153151 153152 153153 153154 153155 153156 153157 153158 153159 153160 153161 153162 153163 153164 153165 153166 153167 153168 153169 153170 153171 153172 153173 153174 | case 12: /* cmd ::= ROLLBACK trans_opt TO savepoint_opt nm */ { sqlite3Savepoint(pParse, SAVEPOINT_ROLLBACK, &yymsp[0].minor.yy0); } break; case 13: /* create_table ::= createkw temp TABLE ifnotexists nm dbnm */ { sqlite3StartTable(pParse,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0,yymsp[-4].minor.yy100,0,0,yymsp[-2].minor.yy100); } break; case 14: /* createkw ::= CREATE */ {disableLookaside(pParse);} break; case 15: /* ifnotexists ::= */ case 18: /* temp ::= */ yytestcase(yyruleno==18); case 21: /* table_options ::= */ yytestcase(yyruleno==21); case 43: /* autoinc ::= */ yytestcase(yyruleno==43); case 58: /* init_deferred_pred_opt ::= */ yytestcase(yyruleno==58); case 68: /* defer_subclause_opt ::= */ yytestcase(yyruleno==68); case 77: /* ifexists ::= */ yytestcase(yyruleno==77); case 94: /* distinct ::= */ yytestcase(yyruleno==94); case 227: /* collate ::= */ yytestcase(yyruleno==227); {yymsp[1].minor.yy100 = 0;} break; case 16: /* ifnotexists ::= IF NOT EXISTS */ {yymsp[-2].minor.yy100 = 1;} break; case 17: /* temp ::= TEMP */ case 44: /* autoinc ::= AUTOINCR */ yytestcase(yyruleno==44); {yymsp[0].minor.yy100 = 1;} break; case 19: /* create_table_args ::= LP columnlist conslist_opt RP table_options */ { sqlite3EndTable(pParse,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0,yymsp[0].minor.yy100,0); } break; case 20: /* create_table_args ::= AS select */ { sqlite3EndTable(pParse,0,0,0,yymsp[0].minor.yy391); sqlite3SelectDelete(pParse->db, yymsp[0].minor.yy391); } break; case 22: /* table_options ::= WITHOUT nm */ { if( yymsp[0].minor.yy0.n==5 && sqlite3_strnicmp(yymsp[0].minor.yy0.z,"rowid",5)==0 ){ yymsp[-1].minor.yy100 = TF_WithoutRowid | TF_NoVisibleRowid; }else{ yymsp[-1].minor.yy100 = 0; sqlite3ErrorMsg(pParse, "unknown table option: %.*s", yymsp[0].minor.yy0.n, yymsp[0].minor.yy0.z); } } break; case 23: /* columnname ::= nm typetoken */ {sqlite3AddColumn(pParse,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0);} break; case 24: /* typetoken ::= */ case 61: /* conslist_opt ::= */ yytestcase(yyruleno==61); case 100: /* as ::= */ yytestcase(yyruleno==100); {yymsp[1].minor.yy0.n = 0; yymsp[1].minor.yy0.z = 0;} break; case 25: /* typetoken ::= typename LP signed RP */ { yymsp[-3].minor.yy0.n = (int)(&yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n] - yymsp[-3].minor.yy0.z); } break; case 26: /* typetoken ::= typename LP signed COMMA signed RP */ { yymsp[-5].minor.yy0.n = (int)(&yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n] - yymsp[-5].minor.yy0.z); } break; case 27: /* typename ::= typename ID|STRING */ {yymsp[-1].minor.yy0.n=yymsp[0].minor.yy0.n+(int)(yymsp[0].minor.yy0.z-yymsp[-1].minor.yy0.z);} break; case 28: /* scanpt ::= */ { assert( yyLookahead!=YYNOCODE ); yymsp[1].minor.yy528 = yyLookaheadToken.z; } break; case 29: /* scantok ::= */ { assert( yyLookahead!=YYNOCODE ); yymsp[1].minor.yy0 = yyLookaheadToken; } break; case 30: /* ccons ::= CONSTRAINT nm */ case 63: /* tcons ::= CONSTRAINT nm */ yytestcase(yyruleno==63); {pParse->constraintName = yymsp[0].minor.yy0;} break; case 31: /* ccons ::= DEFAULT scantok term */ {sqlite3AddDefaultValue(pParse,yymsp[0].minor.yy102,yymsp[-1].minor.yy0.z,&yymsp[-1].minor.yy0.z[yymsp[-1].minor.yy0.n]);} break; case 32: /* ccons ::= DEFAULT LP expr RP */ {sqlite3AddDefaultValue(pParse,yymsp[-1].minor.yy102,yymsp[-2].minor.yy0.z+1,yymsp[0].minor.yy0.z);} break; case 33: /* ccons ::= DEFAULT PLUS scantok term */ {sqlite3AddDefaultValue(pParse,yymsp[0].minor.yy102,yymsp[-2].minor.yy0.z,&yymsp[-1].minor.yy0.z[yymsp[-1].minor.yy0.n]);} break; case 34: /* ccons ::= DEFAULT MINUS scantok term */ { Expr *p = sqlite3PExpr(pParse, TK_UMINUS, yymsp[0].minor.yy102, 0); sqlite3AddDefaultValue(pParse,p,yymsp[-2].minor.yy0.z,&yymsp[-1].minor.yy0.z[yymsp[-1].minor.yy0.n]); } break; case 35: /* ccons ::= DEFAULT scantok ID|INDEXED */ { Expr *p = tokenExpr(pParse, TK_STRING, yymsp[0].minor.yy0); if( p ){ sqlite3ExprIdToTrueFalse(p); testcase( p->op==TK_TRUEFALSE && sqlite3ExprTruthValue(p) ); } sqlite3AddDefaultValue(pParse,p,yymsp[0].minor.yy0.z,yymsp[0].minor.yy0.z+yymsp[0].minor.yy0.n); } break; case 36: /* ccons ::= NOT NULL onconf */ {sqlite3AddNotNull(pParse, yymsp[0].minor.yy100);} break; case 37: /* ccons ::= PRIMARY KEY sortorder onconf autoinc */ {sqlite3AddPrimaryKey(pParse,0,yymsp[-1].minor.yy100,yymsp[0].minor.yy100,yymsp[-2].minor.yy100);} break; case 38: /* ccons ::= UNIQUE onconf */ {sqlite3CreateIndex(pParse,0,0,0,0,yymsp[0].minor.yy100,0,0,0,0, SQLITE_IDXTYPE_UNIQUE);} break; case 39: /* ccons ::= CHECK LP expr RP */ {sqlite3AddCheckConstraint(pParse,yymsp[-1].minor.yy102);} break; case 40: /* ccons ::= REFERENCES nm eidlist_opt refargs */ {sqlite3CreateForeignKey(pParse,0,&yymsp[-2].minor.yy0,yymsp[-1].minor.yy94,yymsp[0].minor.yy100);} break; case 41: /* ccons ::= defer_subclause */ {sqlite3DeferForeignKey(pParse,yymsp[0].minor.yy100);} break; case 42: /* ccons ::= COLLATE ID|STRING */ {sqlite3AddCollateType(pParse, &yymsp[0].minor.yy0);} break; case 45: /* refargs ::= */ { yymsp[1].minor.yy100 = OE_None*0x0101; /* EV: R-19803-45884 */} break; case 46: /* refargs ::= refargs refarg */ { yymsp[-1].minor.yy100 = (yymsp[-1].minor.yy100 & ~yymsp[0].minor.yy199.mask) | yymsp[0].minor.yy199.value; } break; case 47: /* refarg ::= MATCH nm */ { yymsp[-1].minor.yy199.value = 0; yymsp[-1].minor.yy199.mask = 0x000000; } break; case 48: /* refarg ::= ON INSERT refact */ { yymsp[-2].minor.yy199.value = 0; yymsp[-2].minor.yy199.mask = 0x000000; } break; case 49: /* refarg ::= ON DELETE refact */ { yymsp[-2].minor.yy199.value = yymsp[0].minor.yy100; yymsp[-2].minor.yy199.mask = 0x0000ff; } break; case 50: /* refarg ::= ON UPDATE refact */ { yymsp[-2].minor.yy199.value = yymsp[0].minor.yy100<<8; yymsp[-2].minor.yy199.mask = 0x00ff00; } break; case 51: /* refact ::= SET NULL */ { yymsp[-1].minor.yy100 = OE_SetNull; /* EV: R-33326-45252 */} break; case 52: /* refact ::= SET DEFAULT */ { yymsp[-1].minor.yy100 = OE_SetDflt; /* EV: R-33326-45252 */} break; case 53: /* refact ::= CASCADE */ { yymsp[0].minor.yy100 = OE_Cascade; /* EV: R-33326-45252 */} break; case 54: /* refact ::= RESTRICT */ { yymsp[0].minor.yy100 = OE_Restrict; /* EV: R-33326-45252 */} break; case 55: /* refact ::= NO ACTION */ { yymsp[-1].minor.yy100 = OE_None; /* EV: R-33326-45252 */} break; case 56: /* defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt */ {yymsp[-2].minor.yy100 = 0;} break; case 57: /* defer_subclause ::= DEFERRABLE init_deferred_pred_opt */ case 72: /* orconf ::= OR resolvetype */ yytestcase(yyruleno==72); case 157: /* insert_cmd ::= INSERT orconf */ yytestcase(yyruleno==157); {yymsp[-1].minor.yy100 = yymsp[0].minor.yy100;} break; case 59: /* init_deferred_pred_opt ::= INITIALLY DEFERRED */ case 76: /* ifexists ::= IF EXISTS */ yytestcase(yyruleno==76); case 199: /* between_op ::= NOT BETWEEN */ yytestcase(yyruleno==199); case 202: /* in_op ::= NOT IN */ yytestcase(yyruleno==202); case 228: /* collate ::= COLLATE ID|STRING */ yytestcase(yyruleno==228); {yymsp[-1].minor.yy100 = 1;} break; case 60: /* init_deferred_pred_opt ::= INITIALLY IMMEDIATE */ {yymsp[-1].minor.yy100 = 0;} break; case 62: /* tconscomma ::= COMMA */ {pParse->constraintName.n = 0;} break; case 64: /* tcons ::= PRIMARY KEY LP sortlist autoinc RP onconf */ {sqlite3AddPrimaryKey(pParse,yymsp[-3].minor.yy94,yymsp[0].minor.yy100,yymsp[-2].minor.yy100,0);} break; case 65: /* tcons ::= UNIQUE LP sortlist RP onconf */ {sqlite3CreateIndex(pParse,0,0,0,yymsp[-2].minor.yy94,yymsp[0].minor.yy100,0,0,0,0, SQLITE_IDXTYPE_UNIQUE);} break; case 66: /* tcons ::= CHECK LP expr RP onconf */ {sqlite3AddCheckConstraint(pParse,yymsp[-2].minor.yy102);} break; case 67: /* tcons ::= FOREIGN KEY LP eidlist RP REFERENCES nm eidlist_opt refargs defer_subclause_opt */ { sqlite3CreateForeignKey(pParse, yymsp[-6].minor.yy94, &yymsp[-3].minor.yy0, yymsp[-2].minor.yy94, yymsp[-1].minor.yy100); sqlite3DeferForeignKey(pParse, yymsp[0].minor.yy100); } break; case 69: /* onconf ::= */ case 71: /* orconf ::= */ yytestcase(yyruleno==71); {yymsp[1].minor.yy100 = OE_Default;} break; case 70: /* onconf ::= ON CONFLICT resolvetype */ {yymsp[-2].minor.yy100 = yymsp[0].minor.yy100;} break; case 73: /* resolvetype ::= IGNORE */ {yymsp[0].minor.yy100 = OE_Ignore;} break; case 74: /* resolvetype ::= REPLACE */ case 158: /* insert_cmd ::= REPLACE */ yytestcase(yyruleno==158); {yymsp[0].minor.yy100 = OE_Replace;} break; case 75: /* cmd ::= DROP TABLE ifexists fullname */ { sqlite3DropTable(pParse, yymsp[0].minor.yy407, 0, yymsp[-1].minor.yy100); } break; case 78: /* cmd ::= createkw temp VIEW ifnotexists nm dbnm eidlist_opt AS select */ { sqlite3CreateView(pParse, &yymsp[-8].minor.yy0, &yymsp[-4].minor.yy0, &yymsp[-3].minor.yy0, yymsp[-2].minor.yy94, yymsp[0].minor.yy391, yymsp[-7].minor.yy100, yymsp[-5].minor.yy100); } break; case 79: /* cmd ::= DROP VIEW ifexists fullname */ { sqlite3DropTable(pParse, yymsp[0].minor.yy407, 1, yymsp[-1].minor.yy100); } break; case 80: /* cmd ::= select */ { SelectDest dest = {SRT_Output, 0, 0, 0, 0, 0}; sqlite3Select(pParse, yymsp[0].minor.yy391, &dest); sqlite3SelectDelete(pParse->db, yymsp[0].minor.yy391); } break; case 81: /* select ::= WITH wqlist selectnowith */ { Select *p = yymsp[0].minor.yy391; if( p ){ p->pWith = yymsp[-1].minor.yy243; parserDoubleLinkSelect(pParse, p); }else{ sqlite3WithDelete(pParse->db, yymsp[-1].minor.yy243); } yymsp[-2].minor.yy391 = p; } break; case 82: /* select ::= WITH RECURSIVE wqlist selectnowith */ { Select *p = yymsp[0].minor.yy391; if( p ){ p->pWith = yymsp[-1].minor.yy243; parserDoubleLinkSelect(pParse, p); }else{ sqlite3WithDelete(pParse->db, yymsp[-1].minor.yy243); } yymsp[-3].minor.yy391 = p; } break; case 83: /* select ::= selectnowith */ { Select *p = yymsp[0].minor.yy391; if( p ){ parserDoubleLinkSelect(pParse, p); } yymsp[0].minor.yy391 = p; /*A-overwrites-X*/ } break; case 84: /* selectnowith ::= selectnowith multiselect_op oneselect */ { Select *pRhs = yymsp[0].minor.yy391; Select *pLhs = yymsp[-2].minor.yy391; if( pRhs && pRhs->pPrior ){ SrcList *pFrom; Token x; x.n = 0; parserDoubleLinkSelect(pParse, pRhs); pFrom = sqlite3SrcListAppendFromTerm(pParse,0,0,0,&x,pRhs,0,0); pRhs = sqlite3SelectNew(pParse,0,pFrom,0,0,0,0,0,0); } if( pRhs ){ pRhs->op = (u8)yymsp[-1].minor.yy100; pRhs->pPrior = pLhs; if( ALWAYS(pLhs) ) pLhs->selFlags &= ~SF_MultiValue; pRhs->selFlags &= ~SF_MultiValue; if( yymsp[-1].minor.yy100!=TK_ALL ) pParse->hasCompound = 1; }else{ sqlite3SelectDelete(pParse->db, pLhs); } yymsp[-2].minor.yy391 = pRhs; } break; case 85: /* multiselect_op ::= UNION */ case 87: /* multiselect_op ::= EXCEPT|INTERSECT */ yytestcase(yyruleno==87); {yymsp[0].minor.yy100 = yymsp[0].major; /*A-overwrites-OP*/} break; case 86: /* multiselect_op ::= UNION ALL */ {yymsp[-1].minor.yy100 = TK_ALL;} break; case 88: /* oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt orderby_opt limit_opt */ { yymsp[-8].minor.yy391 = sqlite3SelectNew(pParse,yymsp[-6].minor.yy94,yymsp[-5].minor.yy407,yymsp[-4].minor.yy102,yymsp[-3].minor.yy94,yymsp[-2].minor.yy102,yymsp[-1].minor.yy94,yymsp[-7].minor.yy100,yymsp[0].minor.yy102); } break; case 89: /* oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt window_clause orderby_opt limit_opt */ { yymsp[-9].minor.yy391 = sqlite3SelectNew(pParse,yymsp[-7].minor.yy94,yymsp[-6].minor.yy407,yymsp[-5].minor.yy102,yymsp[-4].minor.yy94,yymsp[-3].minor.yy102,yymsp[-1].minor.yy94,yymsp[-8].minor.yy100,yymsp[0].minor.yy102); if( yymsp[-9].minor.yy391 ){ yymsp[-9].minor.yy391->pWinDefn = yymsp[-2].minor.yy379; }else{ sqlite3WindowListDelete(pParse->db, yymsp[-2].minor.yy379); } } break; case 90: /* values ::= VALUES LP nexprlist RP */ { yymsp[-3].minor.yy391 = sqlite3SelectNew(pParse,yymsp[-1].minor.yy94,0,0,0,0,0,SF_Values,0); } break; case 91: /* values ::= values COMMA LP nexprlist RP */ { Select *pRight, *pLeft = yymsp[-4].minor.yy391; pRight = sqlite3SelectNew(pParse,yymsp[-1].minor.yy94,0,0,0,0,0,SF_Values|SF_MultiValue,0); if( ALWAYS(pLeft) ) pLeft->selFlags &= ~SF_MultiValue; if( pRight ){ pRight->op = TK_ALL; pRight->pPrior = pLeft; yymsp[-4].minor.yy391 = pRight; }else{ yymsp[-4].minor.yy391 = pLeft; } } break; case 92: /* distinct ::= DISTINCT */ {yymsp[0].minor.yy100 = SF_Distinct;} break; case 93: /* distinct ::= ALL */ {yymsp[0].minor.yy100 = SF_All;} break; case 95: /* sclp ::= */ case 128: /* orderby_opt ::= */ yytestcase(yyruleno==128); case 135: /* groupby_opt ::= */ yytestcase(yyruleno==135); case 215: /* exprlist ::= */ yytestcase(yyruleno==215); case 218: /* paren_exprlist ::= */ yytestcase(yyruleno==218); case 223: /* eidlist_opt ::= */ yytestcase(yyruleno==223); {yymsp[1].minor.yy94 = 0;} break; case 96: /* selcollist ::= sclp scanpt expr scanpt as */ { yymsp[-4].minor.yy94 = sqlite3ExprListAppend(pParse, yymsp[-4].minor.yy94, yymsp[-2].minor.yy102); if( yymsp[0].minor.yy0.n>0 ) sqlite3ExprListSetName(pParse, yymsp[-4].minor.yy94, &yymsp[0].minor.yy0, 1); sqlite3ExprListSetSpan(pParse,yymsp[-4].minor.yy94,yymsp[-3].minor.yy528,yymsp[-1].minor.yy528); } break; case 97: /* selcollist ::= sclp scanpt STAR */ { Expr *p = sqlite3Expr(pParse->db, TK_ASTERISK, 0); yymsp[-2].minor.yy94 = sqlite3ExprListAppend(pParse, yymsp[-2].minor.yy94, p); } break; case 98: /* selcollist ::= sclp scanpt nm DOT STAR */ { Expr *pRight = sqlite3PExpr(pParse, TK_ASTERISK, 0, 0); Expr *pLeft = sqlite3ExprAlloc(pParse->db, TK_ID, &yymsp[-2].minor.yy0, 1); Expr *pDot = sqlite3PExpr(pParse, TK_DOT, pLeft, pRight); yymsp[-4].minor.yy94 = sqlite3ExprListAppend(pParse,yymsp[-4].minor.yy94, pDot); } break; case 99: /* as ::= AS nm */ case 110: /* dbnm ::= DOT nm */ yytestcase(yyruleno==110); case 239: /* plus_num ::= PLUS INTEGER|FLOAT */ yytestcase(yyruleno==239); case 240: /* minus_num ::= MINUS INTEGER|FLOAT */ yytestcase(yyruleno==240); {yymsp[-1].minor.yy0 = yymsp[0].minor.yy0;} break; case 101: /* from ::= */ {yymsp[1].minor.yy407 = sqlite3DbMallocZero(pParse->db, sizeof(*yymsp[1].minor.yy407));} break; case 102: /* from ::= FROM seltablist */ { yymsp[-1].minor.yy407 = yymsp[0].minor.yy407; sqlite3SrcListShiftJoinType(yymsp[-1].minor.yy407); } break; case 103: /* stl_prefix ::= seltablist joinop */ { if( ALWAYS(yymsp[-1].minor.yy407 && yymsp[-1].minor.yy407->nSrc>0) ) yymsp[-1].minor.yy407->a[yymsp[-1].minor.yy407->nSrc-1].fg.jointype = (u8)yymsp[0].minor.yy100; } break; case 104: /* stl_prefix ::= */ {yymsp[1].minor.yy407 = 0;} break; case 105: /* seltablist ::= stl_prefix nm dbnm as indexed_opt on_opt using_opt */ { yymsp[-6].minor.yy407 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy407,&yymsp[-5].minor.yy0,&yymsp[-4].minor.yy0,&yymsp[-3].minor.yy0,0,yymsp[-1].minor.yy102,yymsp[0].minor.yy76); sqlite3SrcListIndexedBy(pParse, yymsp[-6].minor.yy407, &yymsp[-2].minor.yy0); } break; case 106: /* seltablist ::= stl_prefix nm dbnm LP exprlist RP as on_opt using_opt */ { yymsp[-8].minor.yy407 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-8].minor.yy407,&yymsp[-7].minor.yy0,&yymsp[-6].minor.yy0,&yymsp[-2].minor.yy0,0,yymsp[-1].minor.yy102,yymsp[0].minor.yy76); sqlite3SrcListFuncArgs(pParse, yymsp[-8].minor.yy407, yymsp[-4].minor.yy94); } break; case 107: /* seltablist ::= stl_prefix LP select RP as on_opt using_opt */ { yymsp[-6].minor.yy407 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy407,0,0,&yymsp[-2].minor.yy0,yymsp[-4].minor.yy391,yymsp[-1].minor.yy102,yymsp[0].minor.yy76); } break; case 108: /* seltablist ::= stl_prefix LP seltablist RP as on_opt using_opt */ { if( yymsp[-6].minor.yy407==0 && yymsp[-2].minor.yy0.n==0 && yymsp[-1].minor.yy102==0 && yymsp[0].minor.yy76==0 ){ yymsp[-6].minor.yy407 = yymsp[-4].minor.yy407; }else if( yymsp[-4].minor.yy407->nSrc==1 ){ yymsp[-6].minor.yy407 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy407,0,0,&yymsp[-2].minor.yy0,0,yymsp[-1].minor.yy102,yymsp[0].minor.yy76); if( yymsp[-6].minor.yy407 ){ struct SrcList_item *pNew = &yymsp[-6].minor.yy407->a[yymsp[-6].minor.yy407->nSrc-1]; struct SrcList_item *pOld = yymsp[-4].minor.yy407->a; pNew->zName = pOld->zName; pNew->zDatabase = pOld->zDatabase; pNew->pSelect = pOld->pSelect; if( pOld->fg.isTabFunc ){ pNew->u1.pFuncArg = pOld->u1.pFuncArg; pOld->u1.pFuncArg = 0; pOld->fg.isTabFunc = 0; pNew->fg.isTabFunc = 1; } pOld->zName = pOld->zDatabase = 0; pOld->pSelect = 0; } sqlite3SrcListDelete(pParse->db, yymsp[-4].minor.yy407); }else{ Select *pSubquery; sqlite3SrcListShiftJoinType(yymsp[-4].minor.yy407); pSubquery = sqlite3SelectNew(pParse,0,yymsp[-4].minor.yy407,0,0,0,0,SF_NestedFrom,0); yymsp[-6].minor.yy407 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy407,0,0,&yymsp[-2].minor.yy0,pSubquery,yymsp[-1].minor.yy102,yymsp[0].minor.yy76); } } break; case 109: /* dbnm ::= */ case 123: /* indexed_opt ::= */ yytestcase(yyruleno==123); {yymsp[1].minor.yy0.z=0; yymsp[1].minor.yy0.n=0;} break; case 111: /* fullname ::= nm */ { yylhsminor.yy407 = sqlite3SrcListAppend(pParse,0,&yymsp[0].minor.yy0,0); if( IN_RENAME_OBJECT && yylhsminor.yy407 ) sqlite3RenameTokenMap(pParse, yylhsminor.yy407->a[0].zName, &yymsp[0].minor.yy0); } yymsp[0].minor.yy407 = yylhsminor.yy407; break; case 112: /* fullname ::= nm DOT nm */ { yylhsminor.yy407 = sqlite3SrcListAppend(pParse,0,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0); if( IN_RENAME_OBJECT && yylhsminor.yy407 ) sqlite3RenameTokenMap(pParse, yylhsminor.yy407->a[0].zName, &yymsp[0].minor.yy0); } yymsp[-2].minor.yy407 = yylhsminor.yy407; break; case 113: /* xfullname ::= nm */ {yymsp[0].minor.yy407 = sqlite3SrcListAppend(pParse,0,&yymsp[0].minor.yy0,0); /*A-overwrites-X*/} break; case 114: /* xfullname ::= nm DOT nm */ {yymsp[-2].minor.yy407 = sqlite3SrcListAppend(pParse,0,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0); /*A-overwrites-X*/} break; case 115: /* xfullname ::= nm DOT nm AS nm */ { yymsp[-4].minor.yy407 = sqlite3SrcListAppend(pParse,0,&yymsp[-4].minor.yy0,&yymsp[-2].minor.yy0); /*A-overwrites-X*/ if( yymsp[-4].minor.yy407 ) yymsp[-4].minor.yy407->a[0].zAlias = sqlite3NameFromToken(pParse->db, &yymsp[0].minor.yy0); } break; case 116: /* xfullname ::= nm AS nm */ { yymsp[-2].minor.yy407 = sqlite3SrcListAppend(pParse,0,&yymsp[-2].minor.yy0,0); /*A-overwrites-X*/ if( yymsp[-2].minor.yy407 ) yymsp[-2].minor.yy407->a[0].zAlias = sqlite3NameFromToken(pParse->db, &yymsp[0].minor.yy0); } break; case 117: /* joinop ::= COMMA|JOIN */ { yymsp[0].minor.yy100 = JT_INNER; } break; case 118: /* joinop ::= JOIN_KW JOIN */ {yymsp[-1].minor.yy100 = sqlite3JoinType(pParse,&yymsp[-1].minor.yy0,0,0); /*X-overwrites-A*/} break; case 119: /* joinop ::= JOIN_KW nm JOIN */ {yymsp[-2].minor.yy100 = sqlite3JoinType(pParse,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0,0); /*X-overwrites-A*/} break; case 120: /* joinop ::= JOIN_KW nm nm JOIN */ {yymsp[-3].minor.yy100 = sqlite3JoinType(pParse,&yymsp[-3].minor.yy0,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0);/*X-overwrites-A*/} break; case 121: /* on_opt ::= ON expr */ case 138: /* having_opt ::= HAVING expr */ yytestcase(yyruleno==138); case 145: /* where_opt ::= WHERE expr */ yytestcase(yyruleno==145); case 211: /* case_else ::= ELSE expr */ yytestcase(yyruleno==211); case 232: /* vinto ::= INTO expr */ yytestcase(yyruleno==232); {yymsp[-1].minor.yy102 = yymsp[0].minor.yy102;} break; case 122: /* on_opt ::= */ case 137: /* having_opt ::= */ yytestcase(yyruleno==137); case 139: /* limit_opt ::= */ yytestcase(yyruleno==139); case 144: /* where_opt ::= */ yytestcase(yyruleno==144); case 212: /* case_else ::= */ yytestcase(yyruleno==212); case 214: /* case_operand ::= */ yytestcase(yyruleno==214); case 233: /* vinto ::= */ yytestcase(yyruleno==233); {yymsp[1].minor.yy102 = 0;} break; case 124: /* indexed_opt ::= INDEXED BY nm */ {yymsp[-2].minor.yy0 = yymsp[0].minor.yy0;} break; case 125: /* indexed_opt ::= NOT INDEXED */ {yymsp[-1].minor.yy0.z=0; yymsp[-1].minor.yy0.n=1;} break; case 126: /* using_opt ::= USING LP idlist RP */ {yymsp[-3].minor.yy76 = yymsp[-1].minor.yy76;} break; case 127: /* using_opt ::= */ case 159: /* idlist_opt ::= */ yytestcase(yyruleno==159); {yymsp[1].minor.yy76 = 0;} break; case 129: /* orderby_opt ::= ORDER BY sortlist */ case 136: /* groupby_opt ::= GROUP BY nexprlist */ yytestcase(yyruleno==136); {yymsp[-2].minor.yy94 = yymsp[0].minor.yy94;} break; case 130: /* sortlist ::= sortlist COMMA expr sortorder */ { yymsp[-3].minor.yy94 = sqlite3ExprListAppend(pParse,yymsp[-3].minor.yy94,yymsp[-1].minor.yy102); sqlite3ExprListSetSortOrder(yymsp[-3].minor.yy94,yymsp[0].minor.yy100); } break; case 131: /* sortlist ::= expr sortorder */ { yymsp[-1].minor.yy94 = sqlite3ExprListAppend(pParse,0,yymsp[-1].minor.yy102); /*A-overwrites-Y*/ sqlite3ExprListSetSortOrder(yymsp[-1].minor.yy94,yymsp[0].minor.yy100); } break; case 132: /* sortorder ::= ASC */ {yymsp[0].minor.yy100 = SQLITE_SO_ASC;} break; case 133: /* sortorder ::= DESC */ {yymsp[0].minor.yy100 = SQLITE_SO_DESC;} break; case 134: /* sortorder ::= */ {yymsp[1].minor.yy100 = SQLITE_SO_UNDEFINED;} break; case 140: /* limit_opt ::= LIMIT expr */ {yymsp[-1].minor.yy102 = sqlite3PExpr(pParse,TK_LIMIT,yymsp[0].minor.yy102,0);} break; case 141: /* limit_opt ::= LIMIT expr OFFSET expr */ {yymsp[-3].minor.yy102 = sqlite3PExpr(pParse,TK_LIMIT,yymsp[-2].minor.yy102,yymsp[0].minor.yy102);} break; case 142: /* limit_opt ::= LIMIT expr COMMA expr */ {yymsp[-3].minor.yy102 = sqlite3PExpr(pParse,TK_LIMIT,yymsp[0].minor.yy102,yymsp[-2].minor.yy102);} break; case 143: /* cmd ::= with DELETE FROM xfullname indexed_opt where_opt */ { sqlite3SrcListIndexedBy(pParse, yymsp[-2].minor.yy407, &yymsp[-1].minor.yy0); sqlite3DeleteFrom(pParse,yymsp[-2].minor.yy407,yymsp[0].minor.yy102,0,0); } break; case 146: /* cmd ::= with UPDATE orconf xfullname indexed_opt SET setlist where_opt */ { sqlite3SrcListIndexedBy(pParse, yymsp[-4].minor.yy407, &yymsp[-3].minor.yy0); sqlite3ExprListCheckLength(pParse,yymsp[-1].minor.yy94,"set list"); sqlite3Update(pParse,yymsp[-4].minor.yy407,yymsp[-1].minor.yy94,yymsp[0].minor.yy102,yymsp[-5].minor.yy100,0,0,0); } break; case 147: /* setlist ::= setlist COMMA nm EQ expr */ { yymsp[-4].minor.yy94 = sqlite3ExprListAppend(pParse, yymsp[-4].minor.yy94, yymsp[0].minor.yy102); sqlite3ExprListSetName(pParse, yymsp[-4].minor.yy94, &yymsp[-2].minor.yy0, 1); } break; case 148: /* setlist ::= setlist COMMA LP idlist RP EQ expr */ { yymsp[-6].minor.yy94 = sqlite3ExprListAppendVector(pParse, yymsp[-6].minor.yy94, yymsp[-3].minor.yy76, yymsp[0].minor.yy102); } break; case 149: /* setlist ::= nm EQ expr */ { yylhsminor.yy94 = sqlite3ExprListAppend(pParse, 0, yymsp[0].minor.yy102); sqlite3ExprListSetName(pParse, yylhsminor.yy94, &yymsp[-2].minor.yy0, 1); } yymsp[-2].minor.yy94 = yylhsminor.yy94; break; case 150: /* setlist ::= LP idlist RP EQ expr */ { yymsp[-4].minor.yy94 = sqlite3ExprListAppendVector(pParse, 0, yymsp[-3].minor.yy76, yymsp[0].minor.yy102); } break; case 151: /* cmd ::= with insert_cmd INTO xfullname idlist_opt select upsert */ { sqlite3Insert(pParse, yymsp[-3].minor.yy407, yymsp[-1].minor.yy391, yymsp[-2].minor.yy76, yymsp[-5].minor.yy100, yymsp[0].minor.yy95); } break; case 152: /* cmd ::= with insert_cmd INTO xfullname idlist_opt DEFAULT VALUES */ { sqlite3Insert(pParse, yymsp[-3].minor.yy407, 0, yymsp[-2].minor.yy76, yymsp[-5].minor.yy100, 0); } break; case 153: /* upsert ::= */ { yymsp[1].minor.yy95 = 0; } break; case 154: /* upsert ::= ON CONFLICT LP sortlist RP where_opt DO UPDATE SET setlist where_opt */ { yymsp[-10].minor.yy95 = sqlite3UpsertNew(pParse->db,yymsp[-7].minor.yy94,yymsp[-5].minor.yy102,yymsp[-1].minor.yy94,yymsp[0].minor.yy102);} break; case 155: /* upsert ::= ON CONFLICT LP sortlist RP where_opt DO NOTHING */ { yymsp[-7].minor.yy95 = sqlite3UpsertNew(pParse->db,yymsp[-4].minor.yy94,yymsp[-2].minor.yy102,0,0); } break; case 156: /* upsert ::= ON CONFLICT DO NOTHING */ { yymsp[-3].minor.yy95 = sqlite3UpsertNew(pParse->db,0,0,0,0); } break; case 160: /* idlist_opt ::= LP idlist RP */ {yymsp[-2].minor.yy76 = yymsp[-1].minor.yy76;} break; case 161: /* idlist ::= idlist COMMA nm */ {yymsp[-2].minor.yy76 = sqlite3IdListAppend(pParse,yymsp[-2].minor.yy76,&yymsp[0].minor.yy0);} break; case 162: /* idlist ::= nm */ {yymsp[0].minor.yy76 = sqlite3IdListAppend(pParse,0,&yymsp[0].minor.yy0); /*A-overwrites-Y*/} break; case 163: /* expr ::= LP expr RP */ {yymsp[-2].minor.yy102 = yymsp[-1].minor.yy102;} break; case 164: /* expr ::= ID|INDEXED */ case 165: /* expr ::= JOIN_KW */ yytestcase(yyruleno==165); {yymsp[0].minor.yy102=tokenExpr(pParse,TK_ID,yymsp[0].minor.yy0); /*A-overwrites-X*/} break; case 166: /* expr ::= nm DOT nm */ { Expr *temp1 = sqlite3ExprAlloc(pParse->db, TK_ID, &yymsp[-2].minor.yy0, 1); Expr *temp2 = sqlite3ExprAlloc(pParse->db, TK_ID, &yymsp[0].minor.yy0, 1); if( IN_RENAME_OBJECT ){ sqlite3RenameTokenMap(pParse, (void*)temp2, &yymsp[0].minor.yy0); sqlite3RenameTokenMap(pParse, (void*)temp1, &yymsp[-2].minor.yy0); } yylhsminor.yy102 = sqlite3PExpr(pParse, TK_DOT, temp1, temp2); } yymsp[-2].minor.yy102 = yylhsminor.yy102; break; case 167: /* expr ::= nm DOT nm DOT nm */ { Expr *temp1 = sqlite3ExprAlloc(pParse->db, TK_ID, &yymsp[-4].minor.yy0, 1); Expr *temp2 = sqlite3ExprAlloc(pParse->db, TK_ID, &yymsp[-2].minor.yy0, 1); Expr *temp3 = sqlite3ExprAlloc(pParse->db, TK_ID, &yymsp[0].minor.yy0, 1); Expr *temp4 = sqlite3PExpr(pParse, TK_DOT, temp2, temp3); if( IN_RENAME_OBJECT ){ sqlite3RenameTokenMap(pParse, (void*)temp3, &yymsp[0].minor.yy0); sqlite3RenameTokenMap(pParse, (void*)temp2, &yymsp[-2].minor.yy0); } yylhsminor.yy102 = sqlite3PExpr(pParse, TK_DOT, temp1, temp4); } yymsp[-4].minor.yy102 = yylhsminor.yy102; break; case 168: /* term ::= NULL|FLOAT|BLOB */ case 169: /* term ::= STRING */ yytestcase(yyruleno==169); {yymsp[0].minor.yy102=tokenExpr(pParse,yymsp[0].major,yymsp[0].minor.yy0); /*A-overwrites-X*/} break; case 170: /* term ::= INTEGER */ { yylhsminor.yy102 = sqlite3ExprAlloc(pParse->db, TK_INTEGER, &yymsp[0].minor.yy0, 1); } yymsp[0].minor.yy102 = yylhsminor.yy102; break; case 171: /* expr ::= VARIABLE */ { if( !(yymsp[0].minor.yy0.z[0]=='#' && sqlite3Isdigit(yymsp[0].minor.yy0.z[1])) ){ u32 n = yymsp[0].minor.yy0.n; yymsp[0].minor.yy102 = tokenExpr(pParse, TK_VARIABLE, yymsp[0].minor.yy0); sqlite3ExprAssignVarNumber(pParse, yymsp[0].minor.yy102, n); }else{ /* When doing a nested parse, one can include terms in an expression ** that look like this: #1 #2 ... These terms refer to registers ** in the virtual machine. #N is the N-th register. */ Token t = yymsp[0].minor.yy0; /*A-overwrites-X*/ assert( t.n>=2 ); if( pParse->nested==0 ){ sqlite3ErrorMsg(pParse, "near \"%T\": syntax error", &t); yymsp[0].minor.yy102 = 0; }else{ yymsp[0].minor.yy102 = sqlite3PExpr(pParse, TK_REGISTER, 0, 0); if( yymsp[0].minor.yy102 ) sqlite3GetInt32(&t.z[1], &yymsp[0].minor.yy102->iTable); } } } break; case 172: /* expr ::= expr COLLATE ID|STRING */ { yymsp[-2].minor.yy102 = sqlite3ExprAddCollateToken(pParse, yymsp[-2].minor.yy102, &yymsp[0].minor.yy0, 1); } break; case 173: /* expr ::= CAST LP expr AS typetoken RP */ { yymsp[-5].minor.yy102 = sqlite3ExprAlloc(pParse->db, TK_CAST, &yymsp[-1].minor.yy0, 1); sqlite3ExprAttachSubtrees(pParse->db, yymsp[-5].minor.yy102, yymsp[-3].minor.yy102, 0); } break; case 174: /* expr ::= ID|INDEXED LP distinct exprlist RP */ { yylhsminor.yy102 = sqlite3ExprFunction(pParse, yymsp[-1].minor.yy94, &yymsp[-4].minor.yy0, yymsp[-2].minor.yy100); } yymsp[-4].minor.yy102 = yylhsminor.yy102; break; case 175: /* expr ::= ID|INDEXED LP STAR RP */ { yylhsminor.yy102 = sqlite3ExprFunction(pParse, 0, &yymsp[-3].minor.yy0, 0); } yymsp[-3].minor.yy102 = yylhsminor.yy102; break; case 176: /* expr ::= ID|INDEXED LP distinct exprlist RP over_clause */ { yylhsminor.yy102 = sqlite3ExprFunction(pParse, yymsp[-2].minor.yy94, &yymsp[-5].minor.yy0, yymsp[-3].minor.yy100); sqlite3WindowAttach(pParse, yylhsminor.yy102, yymsp[0].minor.yy379); } yymsp[-5].minor.yy102 = yylhsminor.yy102; break; case 177: /* expr ::= ID|INDEXED LP STAR RP over_clause */ { yylhsminor.yy102 = sqlite3ExprFunction(pParse, 0, &yymsp[-4].minor.yy0, 0); sqlite3WindowAttach(pParse, yylhsminor.yy102, yymsp[0].minor.yy379); } yymsp[-4].minor.yy102 = yylhsminor.yy102; break; case 178: /* term ::= CTIME_KW */ { yylhsminor.yy102 = sqlite3ExprFunction(pParse, 0, &yymsp[0].minor.yy0, 0); } yymsp[0].minor.yy102 = yylhsminor.yy102; break; case 179: /* expr ::= LP nexprlist COMMA expr RP */ { ExprList *pList = sqlite3ExprListAppend(pParse, yymsp[-3].minor.yy94, yymsp[-1].minor.yy102); yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_VECTOR, 0, 0); if( yymsp[-4].minor.yy102 ){ yymsp[-4].minor.yy102->x.pList = pList; }else{ sqlite3ExprListDelete(pParse->db, pList); } } break; case 180: /* expr ::= expr AND expr */ {yymsp[-2].minor.yy102=sqlite3ExprAnd(pParse,yymsp[-2].minor.yy102,yymsp[0].minor.yy102);} break; case 181: /* expr ::= expr OR expr */ case 182: /* expr ::= expr LT|GT|GE|LE expr */ yytestcase(yyruleno==182); case 183: /* expr ::= expr EQ|NE expr */ yytestcase(yyruleno==183); case 184: /* expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr */ yytestcase(yyruleno==184); case 185: /* expr ::= expr PLUS|MINUS expr */ yytestcase(yyruleno==185); case 186: /* expr ::= expr STAR|SLASH|REM expr */ yytestcase(yyruleno==186); case 187: /* expr ::= expr CONCAT expr */ yytestcase(yyruleno==187); {yymsp[-2].minor.yy102=sqlite3PExpr(pParse,yymsp[-1].major,yymsp[-2].minor.yy102,yymsp[0].minor.yy102);} break; case 188: /* likeop ::= NOT LIKE_KW|MATCH */ {yymsp[-1].minor.yy0=yymsp[0].minor.yy0; yymsp[-1].minor.yy0.n|=0x80000000; /*yymsp[-1].minor.yy0-overwrite-yymsp[0].minor.yy0*/} break; case 189: /* expr ::= expr likeop expr */ { ExprList *pList; int bNot = yymsp[-1].minor.yy0.n & 0x80000000; yymsp[-1].minor.yy0.n &= 0x7fffffff; pList = sqlite3ExprListAppend(pParse,0, yymsp[0].minor.yy102); pList = sqlite3ExprListAppend(pParse,pList, yymsp[-2].minor.yy102); yymsp[-2].minor.yy102 = sqlite3ExprFunction(pParse, pList, &yymsp[-1].minor.yy0, 0); if( bNot ) yymsp[-2].minor.yy102 = sqlite3PExpr(pParse, TK_NOT, yymsp[-2].minor.yy102, 0); if( yymsp[-2].minor.yy102 ) yymsp[-2].minor.yy102->flags |= EP_InfixFunc; } break; case 190: /* expr ::= expr likeop expr ESCAPE expr */ { ExprList *pList; int bNot = yymsp[-3].minor.yy0.n & 0x80000000; yymsp[-3].minor.yy0.n &= 0x7fffffff; pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy102); pList = sqlite3ExprListAppend(pParse,pList, yymsp[-4].minor.yy102); pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy102); yymsp[-4].minor.yy102 = sqlite3ExprFunction(pParse, pList, &yymsp[-3].minor.yy0, 0); if( bNot ) yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_NOT, yymsp[-4].minor.yy102, 0); if( yymsp[-4].minor.yy102 ) yymsp[-4].minor.yy102->flags |= EP_InfixFunc; } break; case 191: /* expr ::= expr ISNULL|NOTNULL */ {yymsp[-1].minor.yy102 = sqlite3PExpr(pParse,yymsp[0].major,yymsp[-1].minor.yy102,0);} break; case 192: /* expr ::= expr NOT NULL */ {yymsp[-2].minor.yy102 = sqlite3PExpr(pParse,TK_NOTNULL,yymsp[-2].minor.yy102,0);} break; case 193: /* expr ::= expr IS expr */ { yymsp[-2].minor.yy102 = sqlite3PExpr(pParse,TK_IS,yymsp[-2].minor.yy102,yymsp[0].minor.yy102); binaryToUnaryIfNull(pParse, yymsp[0].minor.yy102, yymsp[-2].minor.yy102, TK_ISNULL); } break; case 194: /* expr ::= expr IS NOT expr */ { yymsp[-3].minor.yy102 = sqlite3PExpr(pParse,TK_ISNOT,yymsp[-3].minor.yy102,yymsp[0].minor.yy102); binaryToUnaryIfNull(pParse, yymsp[0].minor.yy102, yymsp[-3].minor.yy102, TK_NOTNULL); } break; case 195: /* expr ::= NOT expr */ case 196: /* expr ::= BITNOT expr */ yytestcase(yyruleno==196); {yymsp[-1].minor.yy102 = sqlite3PExpr(pParse, yymsp[-1].major, yymsp[0].minor.yy102, 0);/*A-overwrites-B*/} break; case 197: /* expr ::= PLUS|MINUS expr */ { yymsp[-1].minor.yy102 = sqlite3PExpr(pParse, yymsp[-1].major==TK_PLUS ? TK_UPLUS : TK_UMINUS, yymsp[0].minor.yy102, 0); /*A-overwrites-B*/ } break; case 198: /* between_op ::= BETWEEN */ case 201: /* in_op ::= IN */ yytestcase(yyruleno==201); {yymsp[0].minor.yy100 = 0;} break; case 200: /* expr ::= expr between_op expr AND expr */ { ExprList *pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy102); pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy102); yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_BETWEEN, yymsp[-4].minor.yy102, 0); if( yymsp[-4].minor.yy102 ){ yymsp[-4].minor.yy102->x.pList = pList; }else{ sqlite3ExprListDelete(pParse->db, pList); } if( yymsp[-3].minor.yy100 ) yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_NOT, yymsp[-4].minor.yy102, 0); } break; case 203: /* expr ::= expr in_op LP exprlist RP */ { if( yymsp[-1].minor.yy94==0 ){ /* Expressions of the form ** ** expr1 IN () ** expr1 NOT IN () ** ** simplify to constants 0 (false) and 1 (true), respectively, ** regardless of the value of expr1. */ if( IN_RENAME_OBJECT==0 ){ sqlite3ExprDelete(pParse->db, yymsp[-4].minor.yy102); yymsp[-4].minor.yy102 = sqlite3ExprAlloc(pParse->db, TK_INTEGER,&sqlite3IntTokens[yymsp[-3].minor.yy100],1); } }else if( yymsp[-1].minor.yy94->nExpr==1 ){ /* Expressions of the form: ** ** expr1 IN (?1) ** expr1 NOT IN (?2) ** ** with exactly one value on the RHS can be simplified to something ** like this: ** ** expr1 == ?1 ** expr1 <> ?2 ** ** But, the RHS of the == or <> is marked with the EP_Generic flag ** so that it may not contribute to the computation of comparison ** affinity or the collating sequence to use for comparison. Otherwise, ** the semantics would be subtly different from IN or NOT IN. */ Expr *pRHS = yymsp[-1].minor.yy94->a[0].pExpr; yymsp[-1].minor.yy94->a[0].pExpr = 0; sqlite3ExprListDelete(pParse->db, yymsp[-1].minor.yy94); /* pRHS cannot be NULL because a malloc error would have been detected ** before now and control would have never reached this point */ if( ALWAYS(pRHS) ){ pRHS->flags &= ~EP_Collate; pRHS->flags |= EP_Generic; } yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, yymsp[-3].minor.yy100 ? TK_NE : TK_EQ, yymsp[-4].minor.yy102, pRHS); }else{ yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_IN, yymsp[-4].minor.yy102, 0); if( yymsp[-4].minor.yy102 ){ yymsp[-4].minor.yy102->x.pList = yymsp[-1].minor.yy94; sqlite3ExprSetHeightAndFlags(pParse, yymsp[-4].minor.yy102); }else{ sqlite3ExprListDelete(pParse->db, yymsp[-1].minor.yy94); } if( yymsp[-3].minor.yy100 ) yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_NOT, yymsp[-4].minor.yy102, 0); } } break; case 204: /* expr ::= LP select RP */ { yymsp[-2].minor.yy102 = sqlite3PExpr(pParse, TK_SELECT, 0, 0); sqlite3PExprAddSelect(pParse, yymsp[-2].minor.yy102, yymsp[-1].minor.yy391); } break; case 205: /* expr ::= expr in_op LP select RP */ { yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_IN, yymsp[-4].minor.yy102, 0); sqlite3PExprAddSelect(pParse, yymsp[-4].minor.yy102, yymsp[-1].minor.yy391); if( yymsp[-3].minor.yy100 ) yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_NOT, yymsp[-4].minor.yy102, 0); } break; case 206: /* expr ::= expr in_op nm dbnm paren_exprlist */ { SrcList *pSrc = sqlite3SrcListAppend(pParse, 0,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0); Select *pSelect = sqlite3SelectNew(pParse, 0,pSrc,0,0,0,0,0,0); if( yymsp[0].minor.yy94 ) sqlite3SrcListFuncArgs(pParse, pSelect ? pSrc : 0, yymsp[0].minor.yy94); yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_IN, yymsp[-4].minor.yy102, 0); sqlite3PExprAddSelect(pParse, yymsp[-4].minor.yy102, pSelect); if( yymsp[-3].minor.yy100 ) yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_NOT, yymsp[-4].minor.yy102, 0); } break; case 207: /* expr ::= EXISTS LP select RP */ { Expr *p; p = yymsp[-3].minor.yy102 = sqlite3PExpr(pParse, TK_EXISTS, 0, 0); sqlite3PExprAddSelect(pParse, p, yymsp[-1].minor.yy391); } break; case 208: /* expr ::= CASE case_operand case_exprlist case_else END */ { yymsp[-4].minor.yy102 = sqlite3PExpr(pParse, TK_CASE, yymsp[-3].minor.yy102, 0); if( yymsp[-4].minor.yy102 ){ yymsp[-4].minor.yy102->x.pList = yymsp[-1].minor.yy102 ? sqlite3ExprListAppend(pParse,yymsp[-2].minor.yy94,yymsp[-1].minor.yy102) : yymsp[-2].minor.yy94; sqlite3ExprSetHeightAndFlags(pParse, yymsp[-4].minor.yy102); }else{ sqlite3ExprListDelete(pParse->db, yymsp[-2].minor.yy94); sqlite3ExprDelete(pParse->db, yymsp[-1].minor.yy102); } } break; case 209: /* case_exprlist ::= case_exprlist WHEN expr THEN expr */ { yymsp[-4].minor.yy94 = sqlite3ExprListAppend(pParse,yymsp[-4].minor.yy94, yymsp[-2].minor.yy102); yymsp[-4].minor.yy94 = sqlite3ExprListAppend(pParse,yymsp[-4].minor.yy94, yymsp[0].minor.yy102); } break; case 210: /* case_exprlist ::= WHEN expr THEN expr */ { yymsp[-3].minor.yy94 = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy102); yymsp[-3].minor.yy94 = sqlite3ExprListAppend(pParse,yymsp[-3].minor.yy94, yymsp[0].minor.yy102); } break; case 213: /* case_operand ::= expr */ {yymsp[0].minor.yy102 = yymsp[0].minor.yy102; /*A-overwrites-X*/} break; case 216: /* nexprlist ::= nexprlist COMMA expr */ {yymsp[-2].minor.yy94 = sqlite3ExprListAppend(pParse,yymsp[-2].minor.yy94,yymsp[0].minor.yy102);} break; case 217: /* nexprlist ::= expr */ {yymsp[0].minor.yy94 = sqlite3ExprListAppend(pParse,0,yymsp[0].minor.yy102); /*A-overwrites-Y*/} break; case 219: /* paren_exprlist ::= LP exprlist RP */ case 224: /* eidlist_opt ::= LP eidlist RP */ yytestcase(yyruleno==224); {yymsp[-2].minor.yy94 = yymsp[-1].minor.yy94;} break; case 220: /* cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP sortlist RP where_opt */ { sqlite3CreateIndex(pParse, &yymsp[-7].minor.yy0, &yymsp[-6].minor.yy0, sqlite3SrcListAppend(pParse,0,&yymsp[-4].minor.yy0,0), yymsp[-2].minor.yy94, yymsp[-10].minor.yy100, &yymsp[-11].minor.yy0, yymsp[0].minor.yy102, SQLITE_SO_ASC, yymsp[-8].minor.yy100, SQLITE_IDXTYPE_APPDEF); if( IN_RENAME_OBJECT && pParse->pNewIndex ){ sqlite3RenameTokenMap(pParse, pParse->pNewIndex->zName, &yymsp[-4].minor.yy0); } } break; case 221: /* uniqueflag ::= UNIQUE */ case 263: /* raisetype ::= ABORT */ yytestcase(yyruleno==263); {yymsp[0].minor.yy100 = OE_Abort;} break; case 222: /* uniqueflag ::= */ {yymsp[1].minor.yy100 = OE_None;} break; case 225: /* eidlist ::= eidlist COMMA nm collate sortorder */ { yymsp[-4].minor.yy94 = parserAddExprIdListTerm(pParse, yymsp[-4].minor.yy94, &yymsp[-2].minor.yy0, yymsp[-1].minor.yy100, yymsp[0].minor.yy100); } break; case 226: /* eidlist ::= nm collate sortorder */ { yymsp[-2].minor.yy94 = parserAddExprIdListTerm(pParse, 0, &yymsp[-2].minor.yy0, yymsp[-1].minor.yy100, yymsp[0].minor.yy100); /*A-overwrites-Y*/ } break; case 229: /* cmd ::= DROP INDEX ifexists fullname */ {sqlite3DropIndex(pParse, yymsp[0].minor.yy407, yymsp[-1].minor.yy100);} break; case 230: /* cmd ::= VACUUM vinto */ {sqlite3Vacuum(pParse,0,yymsp[0].minor.yy102);} break; case 231: /* cmd ::= VACUUM nm vinto */ {sqlite3Vacuum(pParse,&yymsp[-1].minor.yy0,yymsp[0].minor.yy102);} break; case 234: /* cmd ::= PRAGMA nm dbnm */ {sqlite3Pragma(pParse,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0,0,0);} break; case 235: /* cmd ::= PRAGMA nm dbnm EQ nmnum */ {sqlite3Pragma(pParse,&yymsp[-3].minor.yy0,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0,0);} break; case 236: /* cmd ::= PRAGMA nm dbnm LP nmnum RP */ {sqlite3Pragma(pParse,&yymsp[-4].minor.yy0,&yymsp[-3].minor.yy0,&yymsp[-1].minor.yy0,0);} break; case 237: /* cmd ::= PRAGMA nm dbnm EQ minus_num */ {sqlite3Pragma(pParse,&yymsp[-3].minor.yy0,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0,1);} break; case 238: /* cmd ::= PRAGMA nm dbnm LP minus_num RP */ {sqlite3Pragma(pParse,&yymsp[-4].minor.yy0,&yymsp[-3].minor.yy0,&yymsp[-1].minor.yy0,1);} break; case 241: /* cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END */ { Token all; all.z = yymsp[-3].minor.yy0.z; all.n = (int)(yymsp[0].minor.yy0.z - yymsp[-3].minor.yy0.z) + yymsp[0].minor.yy0.n; sqlite3FinishTrigger(pParse, yymsp[-1].minor.yy11, &all); } break; case 242: /* trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause */ { sqlite3BeginTrigger(pParse, &yymsp[-7].minor.yy0, &yymsp[-6].minor.yy0, yymsp[-5].minor.yy100, yymsp[-4].minor.yy298.a, yymsp[-4].minor.yy298.b, yymsp[-2].minor.yy407, yymsp[0].minor.yy102, yymsp[-10].minor.yy100, yymsp[-8].minor.yy100); yymsp[-10].minor.yy0 = (yymsp[-6].minor.yy0.n==0?yymsp[-7].minor.yy0:yymsp[-6].minor.yy0); /*A-overwrites-T*/ } break; case 243: /* trigger_time ::= BEFORE|AFTER */ { yymsp[0].minor.yy100 = yymsp[0].major; /*A-overwrites-X*/ } break; case 244: /* trigger_time ::= INSTEAD OF */ { yymsp[-1].minor.yy100 = TK_INSTEAD;} break; case 245: /* trigger_time ::= */ { yymsp[1].minor.yy100 = TK_BEFORE; } break; case 246: /* trigger_event ::= DELETE|INSERT */ case 247: /* trigger_event ::= UPDATE */ yytestcase(yyruleno==247); {yymsp[0].minor.yy298.a = yymsp[0].major; /*A-overwrites-X*/ yymsp[0].minor.yy298.b = 0;} break; case 248: /* trigger_event ::= UPDATE OF idlist */ {yymsp[-2].minor.yy298.a = TK_UPDATE; yymsp[-2].minor.yy298.b = yymsp[0].minor.yy76;} break; case 249: /* when_clause ::= */ case 268: /* key_opt ::= */ yytestcase(yyruleno==268); case 316: /* filter_opt ::= */ yytestcase(yyruleno==316); { yymsp[1].minor.yy102 = 0; } break; case 250: /* when_clause ::= WHEN expr */ case 269: /* key_opt ::= KEY expr */ yytestcase(yyruleno==269); { yymsp[-1].minor.yy102 = yymsp[0].minor.yy102; } break; case 251: /* trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI */ { assert( yymsp[-2].minor.yy11!=0 ); yymsp[-2].minor.yy11->pLast->pNext = yymsp[-1].minor.yy11; yymsp[-2].minor.yy11->pLast = yymsp[-1].minor.yy11; } break; case 252: /* trigger_cmd_list ::= trigger_cmd SEMI */ { assert( yymsp[-1].minor.yy11!=0 ); yymsp[-1].minor.yy11->pLast = yymsp[-1].minor.yy11; } break; case 253: /* trnm ::= nm DOT nm */ { yymsp[-2].minor.yy0 = yymsp[0].minor.yy0; sqlite3ErrorMsg(pParse, "qualified table names are not allowed on INSERT, UPDATE, and DELETE " "statements within triggers"); } break; case 254: /* tridxby ::= INDEXED BY nm */ { sqlite3ErrorMsg(pParse, "the INDEXED BY clause is not allowed on UPDATE or DELETE statements " "within triggers"); } break; case 255: /* tridxby ::= NOT INDEXED */ { sqlite3ErrorMsg(pParse, "the NOT INDEXED clause is not allowed on UPDATE or DELETE statements " "within triggers"); } break; case 256: /* trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt scanpt */ {yylhsminor.yy11 = sqlite3TriggerUpdateStep(pParse, &yymsp[-5].minor.yy0, yymsp[-2].minor.yy94, yymsp[-1].minor.yy102, yymsp[-6].minor.yy100, yymsp[-7].minor.yy0.z, yymsp[0].minor.yy528);} yymsp[-7].minor.yy11 = yylhsminor.yy11; break; case 257: /* trigger_cmd ::= scanpt insert_cmd INTO trnm idlist_opt select upsert scanpt */ { yylhsminor.yy11 = sqlite3TriggerInsertStep(pParse,&yymsp[-4].minor.yy0,yymsp[-3].minor.yy76,yymsp[-2].minor.yy391,yymsp[-6].minor.yy100,yymsp[-1].minor.yy95,yymsp[-7].minor.yy528,yymsp[0].minor.yy528);/*yylhsminor.yy11-overwrites-yymsp[-6].minor.yy100*/ } yymsp[-7].minor.yy11 = yylhsminor.yy11; break; case 258: /* trigger_cmd ::= DELETE FROM trnm tridxby where_opt scanpt */ {yylhsminor.yy11 = sqlite3TriggerDeleteStep(pParse, &yymsp[-3].minor.yy0, yymsp[-1].minor.yy102, yymsp[-5].minor.yy0.z, yymsp[0].minor.yy528);} yymsp[-5].minor.yy11 = yylhsminor.yy11; break; case 259: /* trigger_cmd ::= scanpt select scanpt */ {yylhsminor.yy11 = sqlite3TriggerSelectStep(pParse->db, yymsp[-1].minor.yy391, yymsp[-2].minor.yy528, yymsp[0].minor.yy528); /*yylhsminor.yy11-overwrites-yymsp[-1].minor.yy391*/} yymsp[-2].minor.yy11 = yylhsminor.yy11; break; case 260: /* expr ::= RAISE LP IGNORE RP */ { yymsp[-3].minor.yy102 = sqlite3PExpr(pParse, TK_RAISE, 0, 0); if( yymsp[-3].minor.yy102 ){ yymsp[-3].minor.yy102->affinity = OE_Ignore; } } break; case 261: /* expr ::= RAISE LP raisetype COMMA nm RP */ { yymsp[-5].minor.yy102 = sqlite3ExprAlloc(pParse->db, TK_RAISE, &yymsp[-1].minor.yy0, 1); if( yymsp[-5].minor.yy102 ) { yymsp[-5].minor.yy102->affinity = (char)yymsp[-3].minor.yy100; } } break; case 262: /* raisetype ::= ROLLBACK */ {yymsp[0].minor.yy100 = OE_Rollback;} break; case 264: /* raisetype ::= FAIL */ {yymsp[0].minor.yy100 = OE_Fail;} break; case 265: /* cmd ::= DROP TRIGGER ifexists fullname */ { sqlite3DropTrigger(pParse,yymsp[0].minor.yy407,yymsp[-1].minor.yy100); } break; case 266: /* cmd ::= ATTACH database_kw_opt expr AS expr key_opt */ { sqlite3Attach(pParse, yymsp[-3].minor.yy102, yymsp[-1].minor.yy102, yymsp[0].minor.yy102); } break; case 267: /* cmd ::= DETACH database_kw_opt expr */ { sqlite3Detach(pParse, yymsp[0].minor.yy102); } break; case 270: /* cmd ::= REINDEX */ {sqlite3Reindex(pParse, 0, 0);} break; case 271: /* cmd ::= REINDEX nm dbnm */ {sqlite3Reindex(pParse, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0);} break; case 272: /* cmd ::= ANALYZE */ {sqlite3Analyze(pParse, 0, 0);} break; case 273: /* cmd ::= ANALYZE nm dbnm */ {sqlite3Analyze(pParse, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0);} break; case 274: /* cmd ::= ALTER TABLE fullname RENAME TO nm */ { sqlite3AlterRenameTable(pParse,yymsp[-3].minor.yy407,&yymsp[0].minor.yy0); } break; case 275: /* cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt columnname carglist */ { yymsp[-1].minor.yy0.n = (int)(pParse->sLastToken.z-yymsp[-1].minor.yy0.z) + pParse->sLastToken.n; sqlite3AlterFinishAddColumn(pParse, &yymsp[-1].minor.yy0); } break; case 276: /* add_column_fullname ::= fullname */ { disableLookaside(pParse); sqlite3AlterBeginAddColumn(pParse, yymsp[0].minor.yy407); } break; case 277: /* cmd ::= ALTER TABLE fullname RENAME kwcolumn_opt nm TO nm */ { sqlite3AlterRenameColumn(pParse, yymsp[-5].minor.yy407, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); } break; case 278: /* cmd ::= create_vtab */ {sqlite3VtabFinishParse(pParse,0);} break; case 279: /* cmd ::= create_vtab LP vtabarglist RP */ {sqlite3VtabFinishParse(pParse,&yymsp[0].minor.yy0);} break; case 280: /* create_vtab ::= createkw VIRTUAL TABLE ifnotexists nm dbnm USING nm */ { sqlite3VtabBeginParse(pParse, &yymsp[-3].minor.yy0, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-4].minor.yy100); } break; case 281: /* vtabarg ::= */ {sqlite3VtabArgInit(pParse);} break; case 282: /* vtabargtoken ::= ANY */ case 283: /* vtabargtoken ::= lp anylist RP */ yytestcase(yyruleno==283); case 284: /* lp ::= LP */ yytestcase(yyruleno==284); {sqlite3VtabArgExtend(pParse,&yymsp[0].minor.yy0);} break; case 285: /* with ::= WITH wqlist */ case 286: /* with ::= WITH RECURSIVE wqlist */ yytestcase(yyruleno==286); { sqlite3WithPush(pParse, yymsp[0].minor.yy243, 1); } break; case 287: /* wqlist ::= nm eidlist_opt AS LP select RP */ { yymsp[-5].minor.yy243 = sqlite3WithAdd(pParse, 0, &yymsp[-5].minor.yy0, yymsp[-4].minor.yy94, yymsp[-1].minor.yy391); /*A-overwrites-X*/ } break; case 288: /* wqlist ::= wqlist COMMA nm eidlist_opt AS LP select RP */ { yymsp[-7].minor.yy243 = sqlite3WithAdd(pParse, yymsp[-7].minor.yy243, &yymsp[-5].minor.yy0, yymsp[-4].minor.yy94, yymsp[-1].minor.yy391); } break; case 289: /* windowdefn_list ::= windowdefn */ { yylhsminor.yy379 = yymsp[0].minor.yy379; } yymsp[0].minor.yy379 = yylhsminor.yy379; break; case 290: /* windowdefn_list ::= windowdefn_list COMMA windowdefn */ { assert( yymsp[0].minor.yy379!=0 ); sqlite3WindowChain(pParse, yymsp[0].minor.yy379, yymsp[-2].minor.yy379); yymsp[0].minor.yy379->pNextWin = yymsp[-2].minor.yy379; yylhsminor.yy379 = yymsp[0].minor.yy379; } yymsp[-2].minor.yy379 = yylhsminor.yy379; break; case 291: /* windowdefn ::= nm AS LP window RP */ { if( ALWAYS(yymsp[-1].minor.yy379) ){ yymsp[-1].minor.yy379->zName = sqlite3DbStrNDup(pParse->db, yymsp[-4].minor.yy0.z, yymsp[-4].minor.yy0.n); } yylhsminor.yy379 = yymsp[-1].minor.yy379; } yymsp[-4].minor.yy379 = yylhsminor.yy379; break; case 292: /* window ::= PARTITION BY nexprlist orderby_opt frame_opt */ { yymsp[-4].minor.yy379 = sqlite3WindowAssemble(pParse, yymsp[0].minor.yy379, yymsp[-2].minor.yy94, yymsp[-1].minor.yy94, 0); } break; case 293: /* window ::= nm PARTITION BY nexprlist orderby_opt frame_opt */ { yylhsminor.yy379 = sqlite3WindowAssemble(pParse, yymsp[0].minor.yy379, yymsp[-2].minor.yy94, yymsp[-1].minor.yy94, &yymsp[-5].minor.yy0); } yymsp[-5].minor.yy379 = yylhsminor.yy379; break; case 294: /* window ::= ORDER BY sortlist frame_opt */ { yymsp[-3].minor.yy379 = sqlite3WindowAssemble(pParse, yymsp[0].minor.yy379, 0, yymsp[-1].minor.yy94, 0); } break; case 295: /* window ::= nm ORDER BY sortlist frame_opt */ { yylhsminor.yy379 = sqlite3WindowAssemble(pParse, yymsp[0].minor.yy379, 0, yymsp[-1].minor.yy94, &yymsp[-4].minor.yy0); } yymsp[-4].minor.yy379 = yylhsminor.yy379; break; case 296: /* window ::= frame_opt */ { yylhsminor.yy379 = yymsp[0].minor.yy379; } yymsp[0].minor.yy379 = yylhsminor.yy379; break; case 297: /* window ::= nm frame_opt */ { yylhsminor.yy379 = sqlite3WindowAssemble(pParse, yymsp[0].minor.yy379, 0, 0, &yymsp[-1].minor.yy0); } yymsp[-1].minor.yy379 = yylhsminor.yy379; break; case 298: /* frame_opt ::= */ { yymsp[1].minor.yy379 = sqlite3WindowAlloc(pParse, 0, TK_UNBOUNDED, 0, TK_CURRENT, 0, 0); } break; case 299: /* frame_opt ::= range_or_rows frame_bound_s frame_exclude_opt */ { yylhsminor.yy379 = sqlite3WindowAlloc(pParse, yymsp[-2].minor.yy100, yymsp[-1].minor.yy389.eType, yymsp[-1].minor.yy389.pExpr, TK_CURRENT, 0, yymsp[0].minor.yy218); } yymsp[-2].minor.yy379 = yylhsminor.yy379; break; case 300: /* frame_opt ::= range_or_rows BETWEEN frame_bound_s AND frame_bound_e frame_exclude_opt */ { yylhsminor.yy379 = sqlite3WindowAlloc(pParse, yymsp[-5].minor.yy100, yymsp[-3].minor.yy389.eType, yymsp[-3].minor.yy389.pExpr, yymsp[-1].minor.yy389.eType, yymsp[-1].minor.yy389.pExpr, yymsp[0].minor.yy218); } yymsp[-5].minor.yy379 = yylhsminor.yy379; break; case 302: /* frame_bound_s ::= frame_bound */ case 304: /* frame_bound_e ::= frame_bound */ yytestcase(yyruleno==304); {yylhsminor.yy389 = yymsp[0].minor.yy389;} yymsp[0].minor.yy389 = yylhsminor.yy389; break; case 303: /* frame_bound_s ::= UNBOUNDED PRECEDING */ case 305: /* frame_bound_e ::= UNBOUNDED FOLLOWING */ yytestcase(yyruleno==305); case 307: /* frame_bound ::= CURRENT ROW */ yytestcase(yyruleno==307); {yylhsminor.yy389.eType = yymsp[-1].major; yylhsminor.yy389.pExpr = 0;} yymsp[-1].minor.yy389 = yylhsminor.yy389; break; case 306: /* frame_bound ::= expr PRECEDING|FOLLOWING */ {yylhsminor.yy389.eType = yymsp[0].major; yylhsminor.yy389.pExpr = yymsp[-1].minor.yy102;} yymsp[-1].minor.yy389 = yylhsminor.yy389; break; case 308: /* frame_exclude_opt ::= */ {yymsp[1].minor.yy218 = 0;} break; case 309: /* frame_exclude_opt ::= EXCLUDE frame_exclude */ {yymsp[-1].minor.yy218 = yymsp[0].minor.yy218;} break; case 310: /* frame_exclude ::= NO OTHERS */ case 311: /* frame_exclude ::= CURRENT ROW */ yytestcase(yyruleno==311); {yymsp[-1].minor.yy218 = yymsp[-1].major; /*A-overwrites-X*/} break; case 312: /* frame_exclude ::= GROUP|TIES */ {yymsp[0].minor.yy218 = yymsp[0].major; /*A-overwrites-X*/} break; case 313: /* window_clause ::= WINDOW windowdefn_list */ { yymsp[-1].minor.yy379 = yymsp[0].minor.yy379; } break; case 314: /* over_clause ::= filter_opt OVER LP window RP */ { yylhsminor.yy379 = yymsp[-1].minor.yy379; assert( yylhsminor.yy379!=0 ); yylhsminor.yy379->pFilter = yymsp[-4].minor.yy102; } yymsp[-4].minor.yy379 = yylhsminor.yy379; break; case 315: /* over_clause ::= filter_opt OVER nm */ { yylhsminor.yy379 = (Window*)sqlite3DbMallocZero(pParse->db, sizeof(Window)); if( yylhsminor.yy379 ){ yylhsminor.yy379->zName = sqlite3DbStrNDup(pParse->db, yymsp[0].minor.yy0.z, yymsp[0].minor.yy0.n); yylhsminor.yy379->pFilter = yymsp[-2].minor.yy102; }else{ sqlite3ExprDelete(pParse->db, yymsp[-2].minor.yy102); } } yymsp[-2].minor.yy379 = yylhsminor.yy379; break; case 317: /* filter_opt ::= FILTER LP WHERE expr RP */ { yymsp[-4].minor.yy102 = yymsp[-1].minor.yy102; } break; default: /* (318) input ::= cmdlist */ yytestcase(yyruleno==318); /* (319) cmdlist ::= cmdlist ecmd */ yytestcase(yyruleno==319); /* (320) cmdlist ::= ecmd (OPTIMIZED OUT) */ assert(yyruleno!=320); /* (321) ecmd ::= SEMI */ yytestcase(yyruleno==321); /* (322) ecmd ::= cmdx SEMI */ yytestcase(yyruleno==322); /* (323) ecmd ::= explain cmdx */ yytestcase(yyruleno==323); /* (324) trans_opt ::= */ yytestcase(yyruleno==324); /* (325) trans_opt ::= TRANSACTION */ yytestcase(yyruleno==325); /* (326) trans_opt ::= TRANSACTION nm */ yytestcase(yyruleno==326); /* (327) savepoint_opt ::= SAVEPOINT */ yytestcase(yyruleno==327); /* (328) savepoint_opt ::= */ yytestcase(yyruleno==328); /* (329) cmd ::= create_table create_table_args */ yytestcase(yyruleno==329); /* (330) columnlist ::= columnlist COMMA columnname carglist */ yytestcase(yyruleno==330); /* (331) columnlist ::= columnname carglist */ yytestcase(yyruleno==331); /* (332) nm ::= ID|INDEXED */ yytestcase(yyruleno==332); /* (333) nm ::= STRING */ yytestcase(yyruleno==333); /* (334) nm ::= JOIN_KW */ yytestcase(yyruleno==334); /* (335) typetoken ::= typename */ yytestcase(yyruleno==335); /* (336) typename ::= ID|STRING */ yytestcase(yyruleno==336); /* (337) signed ::= plus_num (OPTIMIZED OUT) */ assert(yyruleno!=337); /* (338) signed ::= minus_num (OPTIMIZED OUT) */ assert(yyruleno!=338); /* (339) carglist ::= carglist ccons */ yytestcase(yyruleno==339); /* (340) carglist ::= */ yytestcase(yyruleno==340); /* (341) ccons ::= NULL onconf */ yytestcase(yyruleno==341); /* (342) conslist_opt ::= COMMA conslist */ yytestcase(yyruleno==342); /* (343) conslist ::= conslist tconscomma tcons */ yytestcase(yyruleno==343); /* (344) conslist ::= tcons (OPTIMIZED OUT) */ assert(yyruleno!=344); /* (345) tconscomma ::= */ yytestcase(yyruleno==345); /* (346) defer_subclause_opt ::= defer_subclause (OPTIMIZED OUT) */ assert(yyruleno!=346); /* (347) resolvetype ::= raisetype (OPTIMIZED OUT) */ assert(yyruleno!=347); /* (348) selectnowith ::= oneselect (OPTIMIZED OUT) */ assert(yyruleno!=348); /* (349) oneselect ::= values */ yytestcase(yyruleno==349); /* (350) sclp ::= selcollist COMMA */ yytestcase(yyruleno==350); /* (351) as ::= ID|STRING */ yytestcase(yyruleno==351); /* (352) expr ::= term (OPTIMIZED OUT) */ assert(yyruleno!=352); /* (353) likeop ::= LIKE_KW|MATCH */ yytestcase(yyruleno==353); /* (354) exprlist ::= nexprlist */ yytestcase(yyruleno==354); /* (355) nmnum ::= plus_num (OPTIMIZED OUT) */ assert(yyruleno!=355); /* (356) nmnum ::= nm (OPTIMIZED OUT) */ assert(yyruleno!=356); /* (357) nmnum ::= ON */ yytestcase(yyruleno==357); /* (358) nmnum ::= DELETE */ yytestcase(yyruleno==358); /* (359) nmnum ::= DEFAULT */ yytestcase(yyruleno==359); /* (360) plus_num ::= INTEGER|FLOAT */ yytestcase(yyruleno==360); /* (361) foreach_clause ::= */ yytestcase(yyruleno==361); /* (362) foreach_clause ::= FOR EACH ROW */ yytestcase(yyruleno==362); /* (363) trnm ::= nm */ yytestcase(yyruleno==363); /* (364) tridxby ::= */ yytestcase(yyruleno==364); /* (365) database_kw_opt ::= DATABASE */ yytestcase(yyruleno==365); /* (366) database_kw_opt ::= */ yytestcase(yyruleno==366); /* (367) kwcolumn_opt ::= */ yytestcase(yyruleno==367); /* (368) kwcolumn_opt ::= COLUMNKW */ yytestcase(yyruleno==368); /* (369) vtabarglist ::= vtabarg */ yytestcase(yyruleno==369); /* (370) vtabarglist ::= vtabarglist COMMA vtabarg */ yytestcase(yyruleno==370); /* (371) vtabarg ::= vtabarg vtabargtoken */ yytestcase(yyruleno==371); /* (372) anylist ::= */ yytestcase(yyruleno==372); /* (373) anylist ::= anylist LP anylist RP */ yytestcase(yyruleno==373); /* (374) anylist ::= anylist ANY */ yytestcase(yyruleno==374); /* (375) with ::= */ yytestcase(yyruleno==375); break; /********** End reduce actions ************************************************/ }; assert( yyruleno<sizeof(yyRuleInfoLhs)/sizeof(yyRuleInfoLhs[0]) ); yygoto = yyRuleInfoLhs[yyruleno]; yysize = yyRuleInfoNRhs[yyruleno]; yyact = yy_find_reduce_action(yymsp[yysize].stateno,(YYCODETYPE)yygoto); |
︙ | ︙ | |||
173298 173299 173300 173301 173302 173303 173304 | if( iCol==iCurrent ){ nList = (int)(p - pList); break; } nList -= (int)(p - pList); pList = p; | | | | 173455 173456 173457 173458 173459 173460 173461 173462 173463 173464 173465 173466 173467 173468 173469 173470 173471 173472 173473 173474 173475 173476 | if( iCol==iCurrent ){ nList = (int)(p - pList); break; } nList -= (int)(p - pList); pList = p; if( nList<=0 ){ break; } p = &pList[1]; p += fts3GetVarint32(p, &iCurrent); } if( bZero && (pEnd - &pList[nList])>0){ memset(&pList[nList], 0, pEnd - &pList[nList]); } *ppList = pList; *pnList = nList; } /* |
︙ | ︙ | |||
193870 193871 193872 193873 193874 193875 193876 | rc = xControl(p->pReal, SQLITE_FCNTL_ZIPVFS, &dummy); if( rc==SQLITE_OK ){ rc = SQLITE_ERROR; pRbu->zErrmsg = sqlite3_mprintf("rbu/zipvfs setup error"); }else if( rc==SQLITE_NOTFOUND ){ pRbu->pTargetFd = p; p->pRbu = pRbu; | < | < | 194027 194028 194029 194030 194031 194032 194033 194034 194035 194036 194037 194038 194039 194040 194041 | rc = xControl(p->pReal, SQLITE_FCNTL_ZIPVFS, &dummy); if( rc==SQLITE_OK ){ rc = SQLITE_ERROR; pRbu->zErrmsg = sqlite3_mprintf("rbu/zipvfs setup error"); }else if( rc==SQLITE_NOTFOUND ){ pRbu->pTargetFd = p; p->pRbu = pRbu; rbuMainlistAdd(p); if( p->pWalFd ) p->pWalFd->pRbu = pRbu; rc = SQLITE_OK; } } return rc; } else if( op==SQLITE_FCNTL_RBUCNT ){ |
︙ | ︙ | |||
193935 193936 193937 193938 193939 193940 193941 | /* Magic number 1 is the WAL_CKPT_LOCK lock. Preventing SQLite from ** taking this lock also prevents any checkpoints from occurring. ** todo: really, it's not clear why this might occur, as ** wal_autocheckpoint ought to be turned off. */ if( ofst==WAL_LOCK_CKPT && n==1 ) rc = SQLITE_BUSY; }else{ int bCapture = 0; | < | < < | 194090 194091 194092 194093 194094 194095 194096 194097 194098 194099 194100 194101 194102 194103 194104 | /* Magic number 1 is the WAL_CKPT_LOCK lock. Preventing SQLite from ** taking this lock also prevents any checkpoints from occurring. ** todo: really, it's not clear why this might occur, as ** wal_autocheckpoint ought to be turned off. */ if( ofst==WAL_LOCK_CKPT && n==1 ) rc = SQLITE_BUSY; }else{ int bCapture = 0; if( pRbu && pRbu->eStage==RBU_STAGE_CAPTURE ){ bCapture = 1; } if( bCapture==0 || 0==(flags & SQLITE_SHM_UNLOCK) ){ rc = p->pReal->pMethods->xShmLock(p->pReal, ofst, n, flags); if( bCapture && rc==SQLITE_OK ){ pRbu->mLock |= (1 << ofst); |
︙ | ︙ | |||
193971 193972 193973 193974 193975 193976 193977 | int rc = SQLITE_OK; int eStage = (p->pRbu ? p->pRbu->eStage : 0); /* If not in RBU_STAGE_OAL, allow this call to pass through. Or, if this ** rbu is in the RBU_STAGE_OAL state, use heap memory for *-shm space ** instead of a file on disk. */ assert( p->openFlags & (SQLITE_OPEN_MAIN_DB|SQLITE_OPEN_TEMP_DB) ); | | < | | > > > > > > | | | | | | | | < | | 194123 194124 194125 194126 194127 194128 194129 194130 194131 194132 194133 194134 194135 194136 194137 194138 194139 194140 194141 194142 194143 194144 194145 194146 194147 194148 194149 194150 194151 194152 194153 194154 | int rc = SQLITE_OK; int eStage = (p->pRbu ? p->pRbu->eStage : 0); /* If not in RBU_STAGE_OAL, allow this call to pass through. Or, if this ** rbu is in the RBU_STAGE_OAL state, use heap memory for *-shm space ** instead of a file on disk. */ assert( p->openFlags & (SQLITE_OPEN_MAIN_DB|SQLITE_OPEN_TEMP_DB) ); if( eStage==RBU_STAGE_OAL ){ sqlite3_int64 nByte = (iRegion+1) * sizeof(char*); char **apNew = (char**)sqlite3_realloc64(p->apShm, nByte); /* This is an RBU connection that uses its own heap memory for the ** pages of the *-shm file. Since no other process can have run ** recovery, the connection must request *-shm pages in order ** from start to finish. */ assert( iRegion==p->nShm ); if( apNew==0 ){ rc = SQLITE_NOMEM; }else{ memset(&apNew[p->nShm], 0, sizeof(char*) * (1 + iRegion - p->nShm)); p->apShm = apNew; p->nShm = iRegion+1; } if( rc==SQLITE_OK ){ char *pNew = (char*)sqlite3_malloc64(szRegion); if( pNew==0 ){ rc = SQLITE_NOMEM; }else{ memset(pNew, 0, szRegion); p->apShm[iRegion] = pNew; } |
︙ | ︙ | |||
197207 197208 197209 197210 197211 197212 197213 | if( sqlite3_stricmp(azCol[i], pTo->azCol[i]) ) bMismatch = 1; if( abPK[i] ) bHasPk = 1; } } } sqlite3_free((char*)azCol); if( bMismatch ){ | > | > | 197363 197364 197365 197366 197367 197368 197369 197370 197371 197372 197373 197374 197375 197376 197377 197378 197379 | if( sqlite3_stricmp(azCol[i], pTo->azCol[i]) ) bMismatch = 1; if( abPK[i] ) bHasPk = 1; } } } sqlite3_free((char*)azCol); if( bMismatch ){ if( pzErrMsg ){ *pzErrMsg = sqlite3_mprintf("table schemas do not match"); } rc = SQLITE_SCHEMA; } if( bHasPk==0 ){ /* Ignore tables with no primary keys */ goto diff_out; } } |
︙ | ︙ | |||
197413 197414 197415 197416 197417 197418 197419 | ** Ensure that there is room in the buffer to append nByte bytes of data. ** If not, use sqlite3_realloc() to grow the buffer so that there is. ** ** If successful, return zero. Otherwise, if an OOM condition is encountered, ** set *pRc to SQLITE_NOMEM and return non-zero. */ static int sessionBufferGrow(SessionBuffer *p, size_t nByte, int *pRc){ | | | 197571 197572 197573 197574 197575 197576 197577 197578 197579 197580 197581 197582 197583 197584 197585 | ** Ensure that there is room in the buffer to append nByte bytes of data. ** If not, use sqlite3_realloc() to grow the buffer so that there is. ** ** If successful, return zero. Otherwise, if an OOM condition is encountered, ** set *pRc to SQLITE_NOMEM and return non-zero. */ static int sessionBufferGrow(SessionBuffer *p, size_t nByte, int *pRc){ if( *pRc==SQLITE_OK && (size_t)(p->nAlloc-p->nBuf)<nByte ){ u8 *aNew; i64 nNew = p->nAlloc ? p->nAlloc : 128; do { nNew = nNew*2; }while( (nNew-p->nBuf)<nByte ); aNew = (u8 *)sqlite3_realloc64(p->aBuf, nNew); |
︙ | ︙ | |||
204846 204847 204848 204849 204850 204851 204852 204853 204854 204855 204856 204857 204858 204859 | if( iVal==0 ){ *pi = i; return 0; } fts5FastGetVarint32(a, i, iVal); iOff = ((i64)iVal) << 32; fts5FastGetVarint32(a, i, iVal); } *piOff = iOff + ((iVal-2) & 0x7FFFFFFF); *pi = i; return 0; } } | > > > > > | 205004 205005 205006 205007 205008 205009 205010 205011 205012 205013 205014 205015 205016 205017 205018 205019 205020 205021 205022 | if( iVal==0 ){ *pi = i; return 0; } fts5FastGetVarint32(a, i, iVal); iOff = ((i64)iVal) << 32; fts5FastGetVarint32(a, i, iVal); if( iVal<2 ){ /* This is a corrupt record. So stop parsing it here. */ *piOff = -1; return 1; } } *piOff = iOff + ((iVal-2) & 0x7FFFFFFF); *pi = i; return 0; } } |
︙ | ︙ | |||
214389 214390 214391 214392 214393 214394 214395 | Fts5Buffer tmp = {0, 0, 0}; /* The maximum size of the output is equal to the sum of the two ** input sizes + 1 varint (9 bytes). The extra varint is because if the ** first rowid in one input is a large negative number, and the first in ** the other a non-negative number, the delta for the non-negative ** number will be larger on disk than the literal integer value | | > > > > > > | > > | 214552 214553 214554 214555 214556 214557 214558 214559 214560 214561 214562 214563 214564 214565 214566 214567 214568 214569 214570 214571 214572 214573 214574 214575 214576 214577 214578 214579 214580 214581 214582 214583 214584 214585 214586 214587 214588 214589 214590 214591 214592 | Fts5Buffer tmp = {0, 0, 0}; /* The maximum size of the output is equal to the sum of the two ** input sizes + 1 varint (9 bytes). The extra varint is because if the ** first rowid in one input is a large negative number, and the first in ** the other a non-negative number, the delta for the non-negative ** number will be larger on disk than the literal integer value ** was. ** ** Or, if the input position-lists are corrupt, then the output might ** include up to 2 extra 10-byte positions created by interpreting -1 ** (the value PoslistNext64() uses for EOF) as a position and appending ** it to the output. This can happen at most once for each input ** position-list, hence two 10 byte paddings. */ if( sqlite3Fts5BufferSize(&p->rc, &out, p1->n + p2->n + 9+10+10) ) return; fts5DoclistIterInit(p1, &i1); fts5DoclistIterInit(p2, &i2); while( 1 ){ if( i1.iRowid<i2.iRowid ){ /* Copy entry from i1 */ fts5MergeAppendDocid(&out, iLastRowid, i1.iRowid); fts5BufferSafeAppendBlob(&out, i1.aPoslist, i1.nPoslist+i1.nSize); fts5DoclistIterNext(&i1); if( i1.aPoslist==0 ) break; assert( out.n<=((i1.aPoslist-p1->p) + (i2.aPoslist-p2->p)+9+10+10) ); } else if( i2.iRowid!=i1.iRowid ){ /* Copy entry from i2 */ fts5MergeAppendDocid(&out, iLastRowid, i2.iRowid); fts5BufferSafeAppendBlob(&out, i2.aPoslist, i2.nPoslist+i2.nSize); fts5DoclistIterNext(&i2); if( i2.aPoslist==0 ) break; assert( out.n<=((i1.aPoslist-p1->p) + (i2.aPoslist-p2->p)+9+10+10) ); } else{ /* Merge the two position lists. */ i64 iPos1 = 0; i64 iPos2 = 0; int iOff1 = 0; int iOff2 = 0; |
︙ | ︙ | |||
214431 214432 214433 214434 214435 214436 214437 | fts5MergeAppendDocid(&out, iLastRowid, i2.iRowid); fts5BufferZero(&tmp); sqlite3Fts5BufferSize(&p->rc, &tmp, i1.nPoslist + i2.nPoslist); if( p->rc ) break; sqlite3Fts5PoslistNext64(a1, i1.nPoslist, &iOff1, &iPos1); sqlite3Fts5PoslistNext64(a2, i2.nPoslist, &iOff2, &iPos2); | | < | 214602 214603 214604 214605 214606 214607 214608 214609 214610 214611 214612 214613 214614 214615 214616 214617 214618 214619 214620 214621 214622 214623 214624 | fts5MergeAppendDocid(&out, iLastRowid, i2.iRowid); fts5BufferZero(&tmp); sqlite3Fts5BufferSize(&p->rc, &tmp, i1.nPoslist + i2.nPoslist); if( p->rc ) break; sqlite3Fts5PoslistNext64(a1, i1.nPoslist, &iOff1, &iPos1); sqlite3Fts5PoslistNext64(a2, i2.nPoslist, &iOff2, &iPos2); assert_nc( iPos1>=0 && iPos2>=0 ); if( iPos1<iPos2 ){ sqlite3Fts5PoslistSafeAppend(&tmp, &iPrev, iPos1); sqlite3Fts5PoslistNext64(a1, i1.nPoslist, &iOff1, &iPos1); }else{ sqlite3Fts5PoslistSafeAppend(&tmp, &iPrev, iPos2); sqlite3Fts5PoslistNext64(a2, i2.nPoslist, &iOff2, &iPos2); } if( iPos1>=0 && iPos2>=0 ){ while( 1 ){ if( iPos1<iPos2 ){ if( iPos1!=iPrev ){ sqlite3Fts5PoslistSafeAppend(&tmp, &iPrev, iPos1); } sqlite3Fts5PoslistNext64(a1, i1.nPoslist, &iOff1, &iPos1); |
︙ | ︙ | |||
214465 214466 214467 214468 214469 214470 214471 | if( iPos1>=0 ){ if( iPos1!=iPrev ){ sqlite3Fts5PoslistSafeAppend(&tmp, &iPrev, iPos1); } aCopy = &a1[iOff1]; nCopy = i1.nPoslist - iOff1; }else{ | | | > | | 214635 214636 214637 214638 214639 214640 214641 214642 214643 214644 214645 214646 214647 214648 214649 214650 214651 214652 214653 214654 214655 214656 214657 214658 214659 214660 214661 214662 214663 214664 214665 214666 214667 214668 214669 214670 214671 214672 214673 214674 214675 214676 214677 | if( iPos1>=0 ){ if( iPos1!=iPrev ){ sqlite3Fts5PoslistSafeAppend(&tmp, &iPrev, iPos1); } aCopy = &a1[iOff1]; nCopy = i1.nPoslist - iOff1; }else{ assert_nc( iPos2>=0 && iPos2!=iPrev ); sqlite3Fts5PoslistSafeAppend(&tmp, &iPrev, iPos2); aCopy = &a2[iOff2]; nCopy = i2.nPoslist - iOff2; } if( nCopy>0 ){ fts5BufferSafeAppendBlob(&tmp, aCopy, nCopy); } /* WRITEPOSLISTSIZE */ fts5BufferSafeAppendVarint(&out, tmp.n * 2); fts5BufferSafeAppendBlob(&out, tmp.p, tmp.n); fts5DoclistIterNext(&i1); fts5DoclistIterNext(&i2); assert_nc( out.n<=(p1->n+p2->n+9) ); if( i1.aPoslist==0 || i2.aPoslist==0 ) break; assert( out.n<=((i1.aPoslist-p1->p) + (i2.aPoslist-p2->p)+9+10+10) ); } } if( i1.aPoslist ){ fts5MergeAppendDocid(&out, iLastRowid, i1.iRowid); fts5BufferSafeAppendBlob(&out, i1.aPoslist, i1.aEof - i1.aPoslist); } else if( i2.aPoslist ){ fts5MergeAppendDocid(&out, iLastRowid, i2.iRowid); fts5BufferSafeAppendBlob(&out, i2.aPoslist, i2.aEof - i2.aPoslist); } assert_nc( out.n<=(p1->n+p2->n+9) ); fts5BufferSet(&p->rc, p1, out.n, out.p); fts5BufferFree(&tmp); fts5BufferFree(&out); } } |
︙ | ︙ | |||
218658 218659 218660 218661 218662 218663 218664 | static void fts5SourceIdFunc( sqlite3_context *pCtx, /* Function call context */ int nArg, /* Number of args */ sqlite3_value **apUnused /* Function arguments */ ){ assert( nArg==0 ); UNUSED_PARAM2(nArg, apUnused); | | | 218829 218830 218831 218832 218833 218834 218835 218836 218837 218838 218839 218840 218841 218842 218843 | static void fts5SourceIdFunc( sqlite3_context *pCtx, /* Function call context */ int nArg, /* Number of args */ sqlite3_value **apUnused /* Function arguments */ ){ assert( nArg==0 ); UNUSED_PARAM2(nArg, apUnused); sqlite3_result_text(pCtx, "fts5: 2019-05-23 16:38:12 d2fe370cafa9b11f6c3eb4e1c3be48d9d2610b9d2f9d9ebf9e50267f9079dfc0", -1, SQLITE_TRANSIENT); } /* ** Return true if zName is the extension on one of the shadow tables used ** by this module. */ static int fts5ShadowName(const char *zName){ |
︙ | ︙ | |||
222917 222918 222919 222920 222921 222922 222923 | if( sqlite3Fts5IterEof(pCsr->pIter) ) break; } } } } if( rc==SQLITE_OK && pCsr->bEof==0 && pTab->eType==FTS5_VOCAB_COL ){ | | | > > | 223088 223089 223090 223091 223092 223093 223094 223095 223096 223097 223098 223099 223100 223101 223102 223103 223104 223105 | if( sqlite3Fts5IterEof(pCsr->pIter) ) break; } } } } if( rc==SQLITE_OK && pCsr->bEof==0 && pTab->eType==FTS5_VOCAB_COL ){ for(/* noop */; pCsr->iCol<nCol && pCsr->aDoc[pCsr->iCol]==0; pCsr->iCol++); if( pCsr->iCol==nCol ){ rc = FTS5_CORRUPT; } } return rc; } /* ** This is the xFilter implementation for the virtual table. */ |
︙ | ︙ | |||
223422 223423 223424 223425 223426 223427 223428 | #endif return rc; } #endif /* SQLITE_CORE */ #endif /* !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_STMTVTAB) */ /************** End of stmt.c ************************************************/ | | | | 223595 223596 223597 223598 223599 223600 223601 223602 223603 223604 223605 223606 223607 223608 | #endif return rc; } #endif /* SQLITE_CORE */ #endif /* !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_STMTVTAB) */ /************** End of stmt.c ************************************************/ #if __LINE__!=223602 #undef SQLITE_SOURCE_ID #define SQLITE_SOURCE_ID "2019-05-23 16:38:12 d2fe370cafa9b11f6c3eb4e1c3be48d9d2610b9d2f9d9ebf9e50267f9079alt2" #endif /* Return the source-id for this library */ SQLITE_API const char *sqlite3_sourceid(void){ return SQLITE_SOURCE_ID; } /************************** End of sqlite3.c ******************************/ |
Changes to src/sqlite3.h.
︙ | ︙ | |||
121 122 123 124 125 126 127 | ** ** See also: [sqlite3_libversion()], ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ #define SQLITE_VERSION "3.29.0" #define SQLITE_VERSION_NUMBER 3029000 | | | 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 | ** ** See also: [sqlite3_libversion()], ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ #define SQLITE_VERSION "3.29.0" #define SQLITE_VERSION_NUMBER 3029000 #define SQLITE_SOURCE_ID "2019-05-23 16:38:12 d2fe370cafa9b11f6c3eb4e1c3be48d9d2610b9d2f9d9ebf9e50267f9079dfc0" /* ** CAPI3REF: Run-Time Library Version Numbers ** KEYWORDS: sqlite3_version sqlite3_sourceid ** ** These interfaces provide the same information as the [SQLITE_VERSION], ** [SQLITE_VERSION_NUMBER], and [SQLITE_SOURCE_ID] C preprocessor macros |
︙ | ︙ | |||
2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 | ** <dd>The SQLITE_DBCONFIG_DEFENSIVE option activates or deactivates the ** "defensive" flag for a database connection. When the defensive ** flag is enabled, language features that allow ordinary SQL to ** deliberately corrupt the database file are disabled. The disabled ** features include but are not limited to the following: ** <ul> ** <li> The [PRAGMA writable_schema=ON] statement. ** <li> Writes to the [sqlite_dbpage] virtual table. ** <li> Direct writes to [shadow tables]. ** </ul> ** </dd> ** ** [[SQLITE_DBCONFIG_WRITABLE_SCHEMA]] <dt>SQLITE_DBCONFIG_WRITABLE_SCHEMA</dt> ** <dd>The SQLITE_DBCONFIG_WRITABLE_SCHEMA option activates or deactivates the | > | 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 | ** <dd>The SQLITE_DBCONFIG_DEFENSIVE option activates or deactivates the ** "defensive" flag for a database connection. When the defensive ** flag is enabled, language features that allow ordinary SQL to ** deliberately corrupt the database file are disabled. The disabled ** features include but are not limited to the following: ** <ul> ** <li> The [PRAGMA writable_schema=ON] statement. ** <li> The [PRAGMA journal_mode=OFF] statement. ** <li> Writes to the [sqlite_dbpage] virtual table. ** <li> Direct writes to [shadow tables]. ** </ul> ** </dd> ** ** [[SQLITE_DBCONFIG_WRITABLE_SCHEMA]] <dt>SQLITE_DBCONFIG_WRITABLE_SCHEMA</dt> ** <dd>The SQLITE_DBCONFIG_WRITABLE_SCHEMA option activates or deactivates the |
︙ | ︙ |
Changes to src/tag.c.
︙ | ︙ | |||
752 753 754 755 756 757 758 | blob_reset(&sql); /* Always specify TIMELINE_DISJOINT, or graph_finish() may fail because of too ** many descenders to (off-screen) parents. */ tmFlags = TIMELINE_XMERGE | TIMELINE_FILLGAPS | TIMELINE_NOSCROLL; if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH; if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR; if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR; | | | 752 753 754 755 756 757 758 759 760 761 762 763 | blob_reset(&sql); /* Always specify TIMELINE_DISJOINT, or graph_finish() may fail because of too ** many descenders to (off-screen) parents. */ tmFlags = TIMELINE_XMERGE | TIMELINE_FILLGAPS | TIMELINE_NOSCROLL; if( PB("ng")==0 ) tmFlags |= TIMELINE_GRAPH; if( PB("brbg")!=0 ) tmFlags |= TIMELINE_BRCOLOR; if( PB("ubg")!=0 ) tmFlags |= TIMELINE_UCOLOR; www_print_timeline(&q, tmFlags, 0, 0, 0, 0, 0); db_finalize(&q); @ <br /> style_footer(); } |
Changes to src/timeline.c.
︙ | ︙ | |||
236 237 238 239 240 241 242 | ** 6. background color ** 7. type ("ci", "w", "t", "e", "g", "div") ** 8. list of symbolic tags. ** 9. tagid for ticket or wiki or event ** 10. Short comment to user for repeated tickets and wiki */ void www_print_timeline( | | | | | > | | | 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 | ** 6. background color ** 7. type ("ci", "w", "t", "e", "g", "div") ** 8. list of symbolic tags. ** 9. tagid for ticket or wiki or event ** 10. Short comment to user for repeated tickets and wiki */ void www_print_timeline( Stmt *pQuery, /* Query to implement the timeline */ int tmFlags, /* Flags controlling display behavior */ const char *zThisUser, /* Suppress links to this user */ const char *zThisTag, /* Suppress links to this tag */ const char *zLeftBranch, /* Strive to put this branch on the left margin */ int selectedRid, /* Highlight the line with this RID value */ void (*xExtra)(int) /* Routine to call on each line of display */ ){ int mxWikiLen; Blob comment; int prevTagid = 0; int suppressCnt = 0; char zPrevDate[20]; GraphContext *pGraph = 0; |
︙ | ︙ | |||
757 758 759 760 761 762 763 | @ event%s(suppressCnt>1?"s":"") omitted.</span> suppressCnt = 0; } if( pendingEndTr ){ @ </td></tr> } if( pGraph ){ | | | 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 | @ event%s(suppressCnt>1?"s":"") omitted.</span> suppressCnt = 0; } if( pendingEndTr ){ @ </td></tr> } if( pGraph ){ graph_finish(pGraph, zLeftBranch, tmFlags); if( pGraph->nErr ){ graph_free(pGraph); pGraph = 0; }else{ @ <tr class="timelineBottom" id="btm-%d(iTableId)">\ @ <td></td><td></td><td></td></tr> } |
︙ | ︙ | |||
827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 | int showArrowheads; /* True to draw arrowheads. False to omit. */ int circleNodes; /* True for circle nodes. False for square nodes */ int colorGraph; /* Use colors for graph lines */ int iTopRow; /* Index of the top row of the graph */ int fileDiff; /* True for file diff. False for check-in diff */ int omitDescenders; /* True to omit descenders */ int scrollToSelect; /* True to scroll to the selection */ iRailPitch = atoi(PD("railpitch","0")); showArrowheads = skin_detail_boolean("timeline-arrowheads"); circleNodes = skin_detail_boolean("timeline-circle-nodes"); colorGraph = skin_detail_boolean("timeline-color-graph-lines"); iTopRow = pGraph->pFirst ? pGraph->pFirst->idx : 0; omitDescenders = (tmFlags & TIMELINE_DISJOINT)!=0; fileDiff = (tmFlags & TIMELINE_FILEDIFF)!=0; scrollToSelect = (tmFlags & TIMELINE_NOSCROLL)==0; @ <script id='timeline-data-%d(iTableId)' type='application/json'>{ @ "iTableId": %d(iTableId), @ "circleNodes": %d(circleNodes), @ "showArrowheads": %d(showArrowheads), @ "iRailPitch": %d(iRailPitch), @ "colorGraph": %d(colorGraph), @ "nomo": %d(PB("nomo")), @ "iTopRow": %d(iTopRow), @ "omitDescenders": %d(omitDescenders), @ "fileDiff": %d(fileDiff), @ "scrollToSelect": %d(scrollToSelect), @ "nrail": %d(pGraph->mxRail+1), @ "baseUrl": "%R", @ "bottomRowId": "btm-%d(iTableId)", if( pGraph->nRow==0 ){ @ "rowinfo": null }else{ @ "rowinfo": [ } | > > > > > > > | 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 | int showArrowheads; /* True to draw arrowheads. False to omit. */ int circleNodes; /* True for circle nodes. False for square nodes */ int colorGraph; /* Use colors for graph lines */ int iTopRow; /* Index of the top row of the graph */ int fileDiff; /* True for file diff. False for check-in diff */ int omitDescenders; /* True to omit descenders */ int scrollToSelect; /* True to scroll to the selection */ int dwellTimeout; /* Milliseconds to wait for tooltips to show */ int closeTimeout; /* Milliseconds to wait for tooltips to close */ u8 *aiMap; /* The rail map */ iRailPitch = atoi(PD("railpitch","0")); showArrowheads = skin_detail_boolean("timeline-arrowheads"); circleNodes = skin_detail_boolean("timeline-circle-nodes"); colorGraph = skin_detail_boolean("timeline-color-graph-lines"); iTopRow = pGraph->pFirst ? pGraph->pFirst->idx : 0; omitDescenders = (tmFlags & TIMELINE_DISJOINT)!=0; fileDiff = (tmFlags & TIMELINE_FILEDIFF)!=0; scrollToSelect = (tmFlags & TIMELINE_NOSCROLL)==0; dwellTimeout = atoi(db_get("timeline-dwelltime","100")); closeTimeout = atoi(db_get("timeline-closetime","250")); @ <script id='timeline-data-%d(iTableId)' type='application/json'>{ @ "iTableId": %d(iTableId), @ "circleNodes": %d(circleNodes), @ "showArrowheads": %d(showArrowheads), @ "iRailPitch": %d(iRailPitch), @ "colorGraph": %d(colorGraph), @ "nomo": %d(PB("nomo")), @ "iTopRow": %d(iTopRow), @ "omitDescenders": %d(omitDescenders), @ "fileDiff": %d(fileDiff), @ "scrollToSelect": %d(scrollToSelect), @ "nrail": %d(pGraph->mxRail+1), @ "baseUrl": "%R", @ "dwellTimeout": %d(dwellTimeout), @ "closeTimeout": %d(closeTimeout), @ "bottomRowId": "btm-%d(iTableId)", if( pGraph->nRow==0 ){ @ "rowinfo": null }else{ @ "rowinfo": [ } |
︙ | ︙ | |||
902 903 904 905 906 907 908 909 910 911 912 | ** the screen. This array is omitted if there are no inbound ** merges. ** ci: "cherrypick-in". Like "mi" except for cherrypick merges. ** omitted if there are no cherrypick merges. ** h: The artifact hash of the object being graphed * br: The branch to which the artifact belongs */ for(pRow=pGraph->pFirst; pRow; pRow=pRow->pNext){ int k = 0; cgi_printf("{\"id\":%d,", pRow->idx); cgi_printf("\"bg\":\"%s\",", pRow->zBgClr); | > | | | 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 | ** the screen. This array is omitted if there are no inbound ** merges. ** ci: "cherrypick-in". Like "mi" except for cherrypick merges. ** omitted if there are no cherrypick merges. ** h: The artifact hash of the object being graphed * br: The branch to which the artifact belongs */ aiMap = pGraph->aiRailMap; for(pRow=pGraph->pFirst; pRow; pRow=pRow->pNext){ int k = 0; cgi_printf("{\"id\":%d,", pRow->idx); cgi_printf("\"bg\":\"%s\",", pRow->zBgClr); cgi_printf("\"r\":%d,", aiMap[pRow->iRail]); if( pRow->bDescender ){ cgi_printf("\"d\":%d,", pRow->bDescender); } if( pRow->mergeOut>=0 ){ cgi_printf("\"mo\":%d,", aiMap[pRow->mergeOut]); if( pRow->mergeUpto==0 ) pRow->mergeUpto = pRow->idx; cgi_printf("\"mu\":%d,", pRow->mergeUpto); if( pRow->cherrypickUpto>0 && pRow->cherrypickUpto<pRow->mergeUpto ){ cgi_printf("\"cu\":%d,", pRow->cherrypickUpto); } } if( pRow->isStepParent ){ |
︙ | ︙ | |||
934 935 936 937 938 939 940 | if( i==pRow->iRail ) continue; if( pRow->aiRiser[i]>0 ){ if( k==0 ){ cgi_printf("\"au\":"); cSep = '['; } k++; | | | | | 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 | if( i==pRow->iRail ) continue; if( pRow->aiRiser[i]>0 ){ if( k==0 ){ cgi_printf("\"au\":"); cSep = '['; } k++; cgi_printf("%c%d,%d", cSep, aiMap[i], pRow->aiRiser[i]); cSep = ','; } } if( k ){ cgi_printf("],"); } if( colorGraph && pRow->zBgClr[0]=='#' ){ cgi_printf("\"fg\":\"%s\",", bg_to_fg(pRow->zBgClr)); } /* mi */ for(i=k=0; i<GR_MAX_RAIL; i++){ if( pRow->mergeIn[i]==1 ){ int mi = aiMap[i]; if( (pRow->mergeDown >> i) & 1 ) mi = -mi; if( k==0 ){ cgi_printf("\"mi\":"); cSep = '['; } k++; cgi_printf("%c%d", cSep, mi); cSep = ','; } } if( k ) cgi_printf("],"); /* ci */ for(i=k=0; i<GR_MAX_RAIL; i++){ if( pRow->mergeIn[i]==2 ){ int mi = aiMap[i]; if( (pRow->cherrypickDown >> i) & 1 ) mi = -mi; if( k==0 ){ cgi_printf("\"ci\":"); cSep = '['; } k++; cgi_printf("%c%d", cSep, mi); |
︙ | ︙ | |||
1651 1652 1653 1654 1655 1656 1657 | " WHERE mlink.fid=(SELECT rid FROM blob WHERE uuid LIKE '%q%%')" " AND event.objid=mlink.mid" " ORDER BY event.mtime LIMIT 1", P("cf") ); } | | < < < | 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 | " WHERE mlink.fid=(SELECT rid FROM blob WHERE uuid LIKE '%q%%')" " AND event.objid=mlink.mid" " ORDER BY event.mtime LIMIT 1", P("cf") ); } /* r=TAG works like a combination of t=TAG & rel */ if( zBrName && !related ){ zTagName = zBrName; related = 1; zType = "ci"; } /* Ignore empty tag query strings. */ if( zTagName && !*zTagName ){ |
︙ | ︙ | |||
2392 2393 2394 2395 2396 2397 2398 | if( zError ){ @ <p class="generalError">%h(zError)</p> } if( zNewerButton ){ @ %z(chref("button","%z",zNewerButton))More ↑</a> } | | > | 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 | if( zError ){ @ <p class="generalError">%h(zError)</p> } if( zNewerButton ){ @ %z(chref("button","%z",zNewerButton))More ↑</a> } www_print_timeline(&q, tmFlags, zThisUser, zThisTag, zBrName, selectedRid, 0); db_finalize(&q); if( zOlderButton ){ @ %z(chref("button","%z",zOlderButton))More ↓</a> } style_footer(); } |
︙ | ︙ | |||
2885 2886 2887 2888 2889 2890 2891 | continue; } zId = db_text(0, "SELECT timestamp FROM timeline" " ORDER BY sortby DESC LIMIT 1"); @ <h2>%d(iAgo) Year%s(iAgo>1?"s":"") Ago @ <small>%z(href("%R/timeline?c=%t",zId))(more context)</a>\ @ </small></h2> | | | 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 | continue; } zId = db_text(0, "SELECT timestamp FROM timeline" " ORDER BY sortby DESC LIMIT 1"); @ <h2>%d(iAgo) Year%s(iAgo>1?"s":"") Ago @ <small>%z(href("%R/timeline?c=%t",zId))(more context)</a>\ @ </small></h2> www_print_timeline(&q, TIMELINE_GRAPH, 0, 0, 0, 0, 0); } db_finalize(&q); style_footer(); } /* |
︙ | ︙ |
Changes to src/tkt.c.
︙ | ︙ | |||
894 895 896 897 898 899 900 | " WHERE target=%Q) " "ORDER BY mtime DESC", timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid ); } db_prepare(&q, "%z", zSQL/*safe-for-%s*/); www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH, | | | 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 | " WHERE target=%Q) " "ORDER BY mtime DESC", timeline_query_for_www(), tagid, zFullUuid, zFullUuid, zFullUuid ); } db_prepare(&q, "%z", zSQL/*safe-for-%s*/); www_print_timeline(&q, TIMELINE_ARTID|TIMELINE_DISJOINT|TIMELINE_GRAPH, 0, 0, 0, 0, 0); db_finalize(&q); style_footer(); } /* ** WEBPAGE: tkthistory ** URL: /tkthistory?name=TICKETUUID |
︙ | ︙ |
Changes to test/graph-test-1.wiki.
︙ | ︙ | |||
86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | 1.37 with cherry-pick merges from trunk.</a> * <a href="../../../timeline?f=68bd2e7bedb8d05a" target="testwindow"> Single check-in takes both a full merge and a cherrypick merge</a> * <a href="../../../timeline?b=dc81ac70&n=14" target="testwindow"> Mixed merge arrow, partly fully and partly cherrypick</a> * <a href="../../../timeline?b=dc81ac70&n=13" target="testwindow"> Mixed merge arrow to bottom of screen.</a> External: * <a href="http://www.sqlite.org/src/timeline?c=2010-09-29&nd" target="testwindow">Timewarp due to a mis-configured system clock.</a> * <a href="http://core.tcl.tk/tk/finfo?name=tests/id.test" target="testwindow">Show all three separate deletions of "id.test". (Scroll down for the third deletion.) * <a href='http://core.tcl.tk/tk/timeline?y=ci&b=2015-03-07' target='testwindow'>Merge arrows to the left and to the right</a> * <a href='http://core.tcl.tk/tk/timeline?y=ci&b=2015-03-07&railpitch=13' target='testwindow'>Previous, with a scrunched graph</a> * <a href='http://core.tcl.tk/tk/timeline?y=ci&b=2015-03-07&railpitch=11' target='testwindow'>Previous, with a severely scrunched graph</a> | > > > > > > > > > > > > | 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 | 1.37 with cherry-pick merges from trunk.</a> * <a href="../../../timeline?f=68bd2e7bedb8d05a" target="testwindow"> Single check-in takes both a full merge and a cherrypick merge</a> * <a href="../../../timeline?b=dc81ac70&n=14" target="testwindow"> Mixed merge arrow, partly fully and partly cherrypick</a> * <a href="../../../timeline?b=dc81ac70&n=13" target="testwindow"> Mixed merge arrow to bottom of screen.</a> * <a href="../../../timeline?b=4471e93c&n=12" target="testwindow"> A fork on trunk keeps the longest chain of child nodes directly above the fork and the shorter chain off to the side.</a> * <a href="../../../timeline?r=jan-manifest-tags&n=50" target="testwindow"> The "jan-manifest-tags" branch containing a non-trunk fork</a> * <a href="../../../timeline?r=diff-eolws&n=50" target="testwindow"> The "diff-eolws" branch containing a non-trunk fork</a> * <a href="../../../timeline?n=all&forks" target="testwindow"> All forks</a> External: * <a href="http://www.sqlite.org/src/timeline?c=2010-09-29&nd" target="testwindow">Timewarp due to a mis-configured system clock.</a> * <a href="http://core.tcl.tk/tk/finfo?name=tests/id.test" target="testwindow">Show all three separate deletions of "id.test". (Scroll down for the third deletion.) * <a href='http://core.tcl.tk/tk/timeline?y=ci&b=2015-03-07' target='testwindow'>Merge arrows to the left and to the right</a> * <a href='http://core.tcl.tk/tk/timeline?y=ci&b=2015-03-07&railpitch=13' target='testwindow'>Previous, with a scrunched graph</a> * <a href='http://core.tcl.tk/tk/timeline?y=ci&b=2015-03-07&railpitch=11' target='testwindow'>Previous, with a severely scrunched graph</a> * <a href="https://sqlite.org/src/timeline?r=wal&n=1000" target='testwindow'>The "wal" branch SQLite repository, containing multiple non-trunk forks.</a> |