diff options
author | drh <drh@noemail.net> | 2011-06-03 20:11:17 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2011-06-03 20:11:17 +0000 |
commit | 5d9c9da6e847e7111fc93c592576edaff5ad8cdf (patch) | |
tree | 514f181119aab4e443cf92f438851c98ac627366 /src/build.c | |
parent | 68f2a57698780de49312cdb0f11732c521955d60 (diff) | |
download | sqlite-5d9c9da6e847e7111fc93c592576edaff5ad8cdf.tar.gz sqlite-5d9c9da6e847e7111fc93c592576edaff5ad8cdf.zip |
Create and use a function especially for adding the ParseSchema opcode.
This gives a small reduction in code and a small performance increase.
FossilOrigin-Name: 957b2ab67c6185f0e1062593d237de5c434a38bf
Diffstat (limited to 'src/build.c')
-rw-r--r-- | src/build.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/build.c b/src/build.c index afe208932..97758cbcb 100644 --- a/src/build.c +++ b/src/build.c @@ -1619,8 +1619,8 @@ void sqlite3EndTable( #endif /* Reparse everything to update our internal data structures */ - sqlite3VdbeAddOp4(v, OP_ParseSchema, iDb, 0, 0, - sqlite3MPrintf(db, "tbl_name='%q'",p->zName), P4_DYNAMIC); + sqlite3VdbeAddParseSchemaOp(v, iDb, + sqlite3MPrintf(db, "tbl_name='%q'", p->zName)); } @@ -2817,9 +2817,8 @@ Index *sqlite3CreateIndex( if( pTblName ){ sqlite3RefillIndex(pParse, pIndex, iMem); sqlite3ChangeCookie(pParse, iDb); - sqlite3VdbeAddOp4(v, OP_ParseSchema, iDb, 0, 0, - sqlite3MPrintf(db, "name='%q' AND type='index'", pIndex->zName), - P4_DYNAMIC); + sqlite3VdbeAddParseSchemaOp(v, iDb, + sqlite3MPrintf(db, "name='%q' AND type='index'", pIndex->zName)); sqlite3VdbeAddOp1(v, OP_Expire, 0); } } |