/ Check-in [1925f3a0]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Modify the %nonassoc directive in lemon so that it generates a run-time error rather than a parsing conflict. This changes is due to a bug report on the mailing list. SQLite does not use the %nonassoc directive in its grammar so this change does not affect SQLite.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 1925f3a0a2caa709569df015a8e0d26412f1a9ff
User & Date: drh 2014-06-09 13:11:40
Context
2014-06-09
20:24
Enhance the unix VFS so that it keeps track of the size of unlinked files internally and thus avoids the need to call fstat() on those files, since fstat() does not work reliably on unlinked files on some implementations of FuseFS. check-in: 10707d35 user: drh tags: trunk
20:06
Enhance the unix VFS so that it keeps track of the size of unlinked files internally and thus avoids the need to call fstat() on those files, since fstat() does not work reliably on unlinked files on some implementations of FuseFS. Closed-Leaf check-in: c41df393 user: drh tags: omit-fstat-after-unlink
13:11
Modify the %nonassoc directive in lemon so that it generates a run-time error rather than a parsing conflict. This changes is due to a bug report on the mailing list. SQLite does not use the %nonassoc directive in its grammar so this change does not affect SQLite. check-in: 1925f3a0 user: drh tags: trunk
2014-06-06
20:49
Add a test case to ensure that estLog() works for negative numbers. check-in: 813469d9 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to tool/lemon.c.

  1179   1179         apx->type = SH_RESOLVED;
  1180   1180       }else if( spx->prec==spy->prec && spx->assoc==RIGHT ){ /* Use operator */
  1181   1181         apy->type = RD_RESOLVED;                             /* associativity */
  1182   1182       }else if( spx->prec==spy->prec && spx->assoc==LEFT ){  /* to break tie */
  1183   1183         apx->type = SH_RESOLVED;
  1184   1184       }else{
  1185   1185         assert( spx->prec==spy->prec && spx->assoc==NONE );
  1186         -      apy->type = SRCONFLICT;
  1187         -      errcnt++;
         1186  +      apx->type = ERROR;
  1188   1187       }
  1189   1188     }else if( apx->type==REDUCE && apy->type==REDUCE ){
  1190   1189       spx = apx->x.rp->precsym;
  1191   1190       spy = apy->x.rp->precsym;
  1192   1191       if( spx==0 || spy==0 || spx->prec<0 ||
  1193   1192       spy->prec<0 || spx->prec==spy->prec ){
  1194   1193         apy->type = RRCONFLICT;