aboutsummaryrefslogtreecommitdiff
path: root/src/expr.c
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2012-09-27 15:05:54 +0000
committerdrh <drh@noemail.net>2012-09-27 15:05:54 +0000
commit7e5418e4a487f7579c1249857bf69b7a6985bf32 (patch)
treeeff4f900e32553fefdafc99158c8f5464a95c95f /src/expr.c
parent32634d270ce9de65ac8a1cec14df671a477ce91c (diff)
downloadsqlite-7e5418e4a487f7579c1249857bf69b7a6985bf32.tar.gz
sqlite-7e5418e4a487f7579c1249857bf69b7a6985bf32.zip
Add more bits to the bit vector that is used to disable optimizations for
built-in test. Add specific bit patterns to disable ORDER BY using an index in general and for joins. Use macros to test for bits in the disabled-optimization bit vector, in order to make the code clearer. FossilOrigin-Name: d2fcba1e143beca8c45724d2108870657c269e17
Diffstat (limited to 'src/expr.c')
-rw-r--r--src/expr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/expr.c b/src/expr.c
index 3d6373881..2d1fb38ed 100644
--- a/src/expr.c
+++ b/src/expr.c
@@ -2066,7 +2066,7 @@ void sqlite3ExprCacheStore(Parse *pParse, int iTab, int iCol, int iReg){
** for testing only - to verify that SQLite always gets the same answer
** with and without the column cache.
*/
- if( pParse->db->flags & SQLITE_ColumnCache ) return;
+ if( OptimizationDisabled(pParse->db, SQLITE_ColumnCache) ) return;
/* First replace any existing entry.
**
@@ -3382,7 +3382,7 @@ static int evalConstExpr(Walker *pWalker, Expr *pExpr){
void sqlite3ExprCodeConstants(Parse *pParse, Expr *pExpr){
Walker w;
if( pParse->cookieGoto ) return;
- if( (pParse->db->flags & SQLITE_FactorOutConst)!=0 ) return;
+ if( OptimizationDisabled(pParse->db, SQLITE_FactorOutConst) ) return;
w.xExprCallback = evalConstExpr;
w.xSelectCallback = 0;
w.pParse = pParse;