Fossil SCM
cherry-pick [bfdabaecc8]: Fix the EXPLAIN indenter in the command-line shell to correctly handle NextIfOpen and PrevIfOpen opcodes
Commit
67f148537f7e2e7a2dbf2c343b834426ad673d2c
Parent
927257ea5697d26…
2 files changed
+2
-1
+2
-1
+2
-1
| --- src/shell.c | ||
| +++ src/shell.c | ||
| @@ -1195,11 +1195,12 @@ | ||
| 1195 | 1195 | const char *z; /* Used to check if this is an EXPLAIN */ |
| 1196 | 1196 | int *abYield = 0; /* True if op is an OP_Yield */ |
| 1197 | 1197 | int nAlloc = 0; /* Allocated size of p->aiIndent[], abYield */ |
| 1198 | 1198 | int iOp; /* Index of operation in p->aiIndent[] */ |
| 1199 | 1199 | |
| 1200 | - const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", 0 }; | |
| 1200 | + const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", | |
| 1201 | + "NextIfOpen", "PrevIfOpen", 0 }; | |
| 1201 | 1202 | const char *azYield[] = { "Yield", "SeekLt", "SeekGt", "RowSetRead", "Rewind", 0 }; |
| 1202 | 1203 | const char *azGoto[] = { "Goto", 0 }; |
| 1203 | 1204 | |
| 1204 | 1205 | /* Try to figure out if this is really an EXPLAIN statement. If this |
| 1205 | 1206 | ** cannot be verified, return early. */ |
| 1206 | 1207 |
| --- src/shell.c | |
| +++ src/shell.c | |
| @@ -1195,11 +1195,12 @@ | |
| 1195 | const char *z; /* Used to check if this is an EXPLAIN */ |
| 1196 | int *abYield = 0; /* True if op is an OP_Yield */ |
| 1197 | int nAlloc = 0; /* Allocated size of p->aiIndent[], abYield */ |
| 1198 | int iOp; /* Index of operation in p->aiIndent[] */ |
| 1199 | |
| 1200 | const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", 0 }; |
| 1201 | const char *azYield[] = { "Yield", "SeekLt", "SeekGt", "RowSetRead", "Rewind", 0 }; |
| 1202 | const char *azGoto[] = { "Goto", 0 }; |
| 1203 | |
| 1204 | /* Try to figure out if this is really an EXPLAIN statement. If this |
| 1205 | ** cannot be verified, return early. */ |
| 1206 |
| --- src/shell.c | |
| +++ src/shell.c | |
| @@ -1195,11 +1195,12 @@ | |
| 1195 | const char *z; /* Used to check if this is an EXPLAIN */ |
| 1196 | int *abYield = 0; /* True if op is an OP_Yield */ |
| 1197 | int nAlloc = 0; /* Allocated size of p->aiIndent[], abYield */ |
| 1198 | int iOp; /* Index of operation in p->aiIndent[] */ |
| 1199 | |
| 1200 | const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", |
| 1201 | "NextIfOpen", "PrevIfOpen", 0 }; |
| 1202 | const char *azYield[] = { "Yield", "SeekLt", "SeekGt", "RowSetRead", "Rewind", 0 }; |
| 1203 | const char *azGoto[] = { "Goto", 0 }; |
| 1204 | |
| 1205 | /* Try to figure out if this is really an EXPLAIN statement. If this |
| 1206 | ** cannot be verified, return early. */ |
| 1207 |
+2
-1
| --- src/shell.c | ||
| +++ src/shell.c | ||
| @@ -1195,11 +1195,12 @@ | ||
| 1195 | 1195 | const char *z; /* Used to check if this is an EXPLAIN */ |
| 1196 | 1196 | int *abYield = 0; /* True if op is an OP_Yield */ |
| 1197 | 1197 | int nAlloc = 0; /* Allocated size of p->aiIndent[], abYield */ |
| 1198 | 1198 | int iOp; /* Index of operation in p->aiIndent[] */ |
| 1199 | 1199 | |
| 1200 | - const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", 0 }; | |
| 1200 | + const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", | |
| 1201 | + "NextIfOpen", "PrevIfOpen", 0 }; | |
| 1201 | 1202 | const char *azYield[] = { "Yield", "SeekLt", "SeekGt", "RowSetRead", "Rewind", 0 }; |
| 1202 | 1203 | const char *azGoto[] = { "Goto", 0 }; |
| 1203 | 1204 | |
| 1204 | 1205 | /* Try to figure out if this is really an EXPLAIN statement. If this |
| 1205 | 1206 | ** cannot be verified, return early. */ |
| 1206 | 1207 |
| --- src/shell.c | |
| +++ src/shell.c | |
| @@ -1195,11 +1195,12 @@ | |
| 1195 | const char *z; /* Used to check if this is an EXPLAIN */ |
| 1196 | int *abYield = 0; /* True if op is an OP_Yield */ |
| 1197 | int nAlloc = 0; /* Allocated size of p->aiIndent[], abYield */ |
| 1198 | int iOp; /* Index of operation in p->aiIndent[] */ |
| 1199 | |
| 1200 | const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", 0 }; |
| 1201 | const char *azYield[] = { "Yield", "SeekLt", "SeekGt", "RowSetRead", "Rewind", 0 }; |
| 1202 | const char *azGoto[] = { "Goto", 0 }; |
| 1203 | |
| 1204 | /* Try to figure out if this is really an EXPLAIN statement. If this |
| 1205 | ** cannot be verified, return early. */ |
| 1206 |
| --- src/shell.c | |
| +++ src/shell.c | |
| @@ -1195,11 +1195,12 @@ | |
| 1195 | const char *z; /* Used to check if this is an EXPLAIN */ |
| 1196 | int *abYield = 0; /* True if op is an OP_Yield */ |
| 1197 | int nAlloc = 0; /* Allocated size of p->aiIndent[], abYield */ |
| 1198 | int iOp; /* Index of operation in p->aiIndent[] */ |
| 1199 | |
| 1200 | const char *azNext[] = { "Next", "Prev", "VPrev", "VNext", "SorterNext", |
| 1201 | "NextIfOpen", "PrevIfOpen", 0 }; |
| 1202 | const char *azYield[] = { "Yield", "SeekLt", "SeekGt", "RowSetRead", "Rewind", 0 }; |
| 1203 | const char *azGoto[] = { "Goto", 0 }; |
| 1204 | |
| 1205 | /* Try to figure out if this is really an EXPLAIN statement. If this |
| 1206 | ** cannot be verified, return early. */ |
| 1207 |