diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 22:19:39 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 22:19:39 +0000 |
commit | 04766b207afba7961d4d802313e426f5a2fbef63 (patch) | |
tree | c888ea1027c793e2d0386a7e5a1a0cd077b03cb3 /kexi/3rdparty/kexisql | |
parent | b6edfe41c9395f2e20784cbf0e630af6426950a3 (diff) | |
download | koffice-04766b207afba7961d4d802313e426f5a2fbef63.tar.gz koffice-04766b207afba7961d4d802313e426f5a2fbef63.zip |
rename the following methods:
tqparent parent
tqmask mask
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1246260 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kexi/3rdparty/kexisql')
-rw-r--r-- | kexi/3rdparty/kexisql/src/btree.c | 36 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/btree_rb.c | 46 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/func.c | 14 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/parse.c | 12 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/parse.y | 12 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/pragma.c | 8 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/select.c | 10 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/sqliteInt.h | 4 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/src/where.c | 56 | ||||
-rw-r--r-- | kexi/3rdparty/kexisql/tool/lemon.c | 6 |
10 files changed, 102 insertions, 102 deletions
diff --git a/kexi/3rdparty/kexisql/src/btree.c b/kexi/3rdparty/kexisql/src/btree.c index a257011e..edcba8c9 100644 --- a/kexi/3rdparty/kexisql/src/btree.c +++ b/kexi/3rdparty/kexisql/src/btree.c @@ -313,9 +313,9 @@ struct FreelistInfo { ** page to hold as many as two more cells than it might otherwise hold. ** The extra two entries in apCell[] are an allowance for this situation. ** -** The pParent field points back to the tqparent page. This allows us to +** The pParent field points back to the parent page. This allows us to ** walk up the BTree from any leaf to the root. Care must be taken to -** unref() the tqparent page pointer when this page is no longer referenced. +** unref() the parent page pointer when this page is no longer referenced. ** The pageDestructor() routine handles that chore. */ struct MemPage { @@ -326,7 +326,7 @@ struct MemPage { u8 isInit; /* True if auxiliary data is initialized */ u8 idxShift; /* True if apCell[] indices have changed */ u8 isOverfull; /* Some apCell[] points outside u.aDisk[] */ - MemPage *pParent; /* The tqparent of this page. NULL for root */ + MemPage *pParent; /* The parent of this page. NULL for root */ int idxParent; /* Index in pParent->apCell[] of this node */ int nFree; /* Number of free bytes in u.aDisk[] */ int nCell; /* Number of entries on this page */ @@ -567,8 +567,8 @@ static void freeSpace(Btree *pBt, MemPage *pPage, int start, int size){ ** Initialize the auxiliary information for a disk block. ** ** The pParent parameter must be a pointer to the MemPage which -** is the tqparent of the page being initialized. The root of the -** BTree (usually page 2) has no tqparent and so for that page, +** is the parent of the page being initialized. The root of the +** BTree (usually page 2) has no parent and so for that page, ** pParent==NULL. ** ** Return SQLITE_OK on success. If we see that the page does @@ -1414,7 +1414,7 @@ static int moveToChild(BtCursor *pCur, int newPgno){ } /* -** Move the cursor up to the tqparent page. +** Move the cursor up to the parent page. ** ** pCur->idx is set to the cell index that contains the pointer ** to the page we are coming from. If we are coming from the @@ -1451,7 +1451,7 @@ static void moveToParent(BtCursor *pCur){ }else{ /* The MemPage.idxShift flag indicates that cell indices might have ** changed since idxParent was set and hence idxParent might be out - ** of date. So recompute the tqparent cell index by scanning all cells + ** of date. So recompute the parent cell index by scanning all cells ** and locating the one that points to the child we just came from. */ int i; @@ -1998,9 +1998,9 @@ static void reparentPage(Pager *pPager, Pgno pgno, MemPage *pNewParent,int idx){ } /* -** Retqparent all tqchildren of the given page to be the given page. +** Reparent all tqchildren of the given page to be the given page. ** In other words, for every child of pPage, invoke reparentPage() -** to make sure that each child knows that pPage is its tqparent. +** to make sure that each child knows that pPage is its parent. ** ** This routine gets called after you memcpy() one page into ** another. @@ -2141,7 +2141,7 @@ static void copyPage(MemPage *pTo, MemPage *pFrom){ ** of pPage so that all pages have about the same amount of free space. ** Usually one sibling on either side of pPage is used in the balancing, ** though both siblings might come from one side if pPage is the first -** or last child of its tqparent. If pPage has fewer than two siblings +** or last child of its parent. If pPage has fewer than two siblings ** (something which can only happen if pPage is the root page or a ** child of root) then all available siblings participate in the balancing. ** @@ -2168,16 +2168,16 @@ static void copyPage(MemPage *pTo, MemPage *pFrom){ ** if the page is overfull. Part of the job of this routine is to ** make sure all Cells for pPage once again fit in pPage->u.aDisk[]. ** -** In the course of balancing the siblings of pPage, the tqparent of pPage +** In the course of balancing the siblings of pPage, the parent of pPage ** might become overfull or underfull. If that happens, then this routine -** is called recursively on the tqparent. +** is called recursively on the parent. ** ** If this routine fails for any reason, it might leave the database ** in a corrupted state. So if this routine fails, the database should ** be rolled back. */ static int balance(Btree *pBt, MemPage *pPage, BtCursor *pCur){ - MemPage *pParent; /* The tqparent of pPage */ + MemPage *pParent; /* The parent of pPage */ int nCell; /* Number of cells in apCell[] */ int nOld; /* Number of pages in apOld[] */ int nNew; /* Number of pages in apNew[] */ @@ -2215,8 +2215,8 @@ static int balance(Btree *pBt, MemPage *pPage, BtCursor *pCur){ } /* - ** Find the tqparent of the page to be balanceed. - ** If there is no tqparent, it means this page is the root page and + ** Find the parent of the page to be balanceed. + ** If there is no parent, it means this page is the root page and ** special rules apply. */ pParent = pPage->pParent; @@ -2291,7 +2291,7 @@ static int balance(Btree *pBt, MemPage *pPage, BtCursor *pCur){ assert( pParent->isInit ); /* - ** Find the Cell in the tqparent page whose h.leftChild points back + ** Find the Cell in the parent page whose h.leftChild points back ** to pPage. The "idx" variable is the index of that cell. If pPage ** is the rightmost child of pParent then set idx to pParent->nCell */ @@ -2547,7 +2547,7 @@ static int balance(Btree *pBt, MemPage *pPage, BtCursor *pCur){ } /* - ** Retqparent tqchildren of all cells. + ** Reparent tqchildren of all cells. */ for(i=0; i<nNew; i++){ reparentChildPages(pBt, apNew[i]); @@ -2555,7 +2555,7 @@ static int balance(Btree *pBt, MemPage *pPage, BtCursor *pCur){ reparentChildPages(pBt, pParent); /* - ** balance the tqparent page. + ** balance the parent page. */ rc = balance(pBt, pParent, pCur); diff --git a/kexi/3rdparty/kexisql/src/btree_rb.c b/kexi/3rdparty/kexisql/src/btree_rb.c index afb2c508..86feaa5b 100644 --- a/kexi/3rdparty/kexisql/src/btree_rb.c +++ b/kexi/3rdparty/kexisql/src/btree_rb.c @@ -123,7 +123,7 @@ struct BtRbNode { int nData; void *pData; u8 isBlack; /* true for a black node, 0 for a red node */ - BtRbNode *pParent; /* Nodes tqparent node, NULL for the tree head */ + BtRbNode *pParent; /* Nodes parent node, NULL for the tree head */ BtRbNode *pLeft; /* Nodes left child, or NULL */ BtRbNode *pRight; /* Nodes right child, or NULL */ @@ -329,7 +329,7 @@ static void check_redblack_tree(BtRbTree * tree, char ** msg) { BtRbNode *pNode; - /* 0 -> came from tqparent + /* 0 -> came from parent * 1 -> came from left * 2 -> came from right */ int prev_step = 0; @@ -400,34 +400,34 @@ static void check_redblack_tree(BtRbTree * tree, char ** msg) /* * Node pX has just been inserted into pTree (by code in sqliteRbtreeInsert()). - * It is possible that pX is a red node with a red tqparent, which is a violation + * It is possible that pX is a red node with a red parent, which is a violation * of the red-black tree properties. This function performs rotations and * color changes to rebalance the tree */ static void do_insert_balancing(BtRbTree *pTree, BtRbNode *pX) { /* In the first iteration of this loop, pX points to the red node just - * inserted in the tree. If the tqparent of pX exists (pX is not the root + * inserted in the tree. If the parent of pX exists (pX is not the root * node) and is red, then the properties of the red-black tree are * violated. * * At the start of any subsequent iterations, pX points to a red node - * with a red tqparent. In all other respects the tree is a legal red-black + * with a red parent. In all other respects the tree is a legal red-black * binary tree. */ while( pX != pTree->pHead && !pX->pParent->isBlack ){ BtRbNode *pUncle; - BtRbNode *pGrandtqparent; + BtRbNode *pGrandparent; - /* Grandtqparent of pX must exist and must be black. */ - pGrandtqparent = pX->pParent->pParent; - assert( pGrandtqparent ); - assert( pGrandtqparent->isBlack ); + /* Grandparent of pX must exist and must be black. */ + pGrandparent = pX->pParent->pParent; + assert( pGrandparent ); + assert( pGrandparent->isBlack ); /* Uncle of pX may or may not exist. */ - if( pX->pParent == pGrandtqparent->pLeft ) - pUncle = pGrandtqparent->pRight; + if( pX->pParent == pGrandparent->pLeft ) + pUncle = pGrandparent->pRight; else - pUncle = pGrandtqparent->pLeft; + pUncle = pGrandparent->pLeft; /* If the uncle of pX exists and is red, we do the following: * | | @@ -438,16 +438,16 @@ static void do_insert_balancing(BtRbTree *pTree, BtRbNode *pX) * X(r) X(r) * * BEFORE AFTER - * pX is then set to G. If the tqparent of G is red, then the while loop + * pX is then set to G. If the parent of G is red, then the while loop * will run again. */ if( pUncle && !pUncle->isBlack ){ - pGrandtqparent->isBlack = 0; + pGrandparent->isBlack = 0; pUncle->isBlack = 1; pX->pParent->isBlack = 1; - pX = pGrandtqparent; + pX = pGrandparent; }else{ - if( pX->pParent == pGrandtqparent->pLeft ){ + if( pX->pParent == pGrandparent->pLeft ){ if( pX == pX->pParent->pRight ){ /* If pX is a right-child, do the following transform, essentially * to change pX into a left-child: @@ -474,10 +474,10 @@ static void do_insert_balancing(BtRbTree *pTree, BtRbNode *pX) * * BEFORE AFTER */ - assert( pGrandtqparent == pX->pParent->pParent ); - pGrandtqparent->isBlack = 0; + assert( pGrandparent == pX->pParent->pParent ); + pGrandparent->isBlack = 0; pX->pParent->isBlack = 1; - rightRotate( pTree, pGrandtqparent ); + rightRotate( pTree, pGrandparent ); }else{ /* This code is symetric to the illustrated case above. */ @@ -485,10 +485,10 @@ static void do_insert_balancing(BtRbTree *pTree, BtRbNode *pX) pX = pX->pParent; rightRotate(pTree, pX); } - assert( pGrandtqparent == pX->pParent->pParent ); - pGrandtqparent->isBlack = 0; + assert( pGrandparent == pX->pParent->pParent ); + pGrandparent->isBlack = 0; pX->pParent->isBlack = 1; - leftRotate( pTree, pGrandtqparent ); + leftRotate( pTree, pGrandparent ); } } } diff --git a/kexi/3rdparty/kexisql/src/func.c b/kexi/3rdparty/kexisql/src/func.c index cf0b8baf..0fcc291e 100644 --- a/kexi/3rdparty/kexisql/src/func.c +++ b/kexi/3rdparty/kexisql/src/func.c @@ -32,10 +32,10 @@ static void minmaxFunc(sqlite_func *context, int argc, const char **argv){ const char *zBest; int i; int (*xCompare)(const char*, const char*); - int tqmask; /* 0 for min() or 0xffffffff for max() */ + int mask; /* 0 for min() or 0xffffffff for max() */ if( argc==0 ) return; - tqmask = (int)sqlite_user_data(context); + mask = (int)sqlite_user_data(context); zBest = argv[0]; if( zBest==0 ) return; if( argv[1][0]=='n' ){ @@ -45,7 +45,7 @@ static void minmaxFunc(sqlite_func *context, int argc, const char **argv){ } for(i=2; i<argc; i+=2){ if( argv[i]==0 ) return; - if( (xCompare(argv[i], zBest)^tqmask)<0 ){ + if( (xCompare(argv[i], zBest)^mask)<0 ){ zBest = argv[i]; } } @@ -514,7 +514,7 @@ struct MinMaxCtx { static void minmaxStep(sqlite_func *context, int argc, const char **argv){ MinMaxCtx *p; int (*xCompare)(const char*, const char*); - int tqmask; /* 0 for min() or 0xffffffff for max() */ + int mask; /* 0 for min() or 0xffffffff for max() */ assert( argc==2 ); if( argv[0]==0 ) return; /* Ignore NULL values */ @@ -523,11 +523,11 @@ static void minmaxStep(sqlite_func *context, int argc, const char **argv){ }else{ xCompare = strcmp; } - tqmask = (int)sqlite_user_data(context); - assert( tqmask==0 || tqmask==-1 ); + mask = (int)sqlite_user_data(context); + assert( mask==0 || mask==-1 ); p = sqlite_aggregate_context(context, sizeof(*p)); if( p==0 || argc<1 ) return; - if( p->z==0 || (xCompare(argv[0],p->z)^tqmask)<0 ){ + if( p->z==0 || (xCompare(argv[0],p->z)^mask)<0 ){ int len; if( p->zBuf[0] ){ sqliteFree(p->z); diff --git a/kexi/3rdparty/kexisql/src/parse.c b/kexi/3rdparty/kexisql/src/parse.c index 77b09c5b..2fd6ae39 100644 --- a/kexi/3rdparty/kexisql/src/parse.c +++ b/kexi/3rdparty/kexisql/src/parse.c @@ -97,7 +97,7 @@ typedef union { IdList* yy320; ExprList* yy322; int yy372; - struct {int value; int tqmask;} yy407; + struct {int value; int mask;} yy407; int yy441; } YYMINORTYPE; #define YYSTACKDEPTH 100 @@ -2218,33 +2218,33 @@ static void yy_reduce( break; case 62: #line 207 "parse.y" -{ yygotominor.yy372 = (yymsp[-1].minor.yy372 & yymsp[0].minor.yy407.tqmask) | yymsp[0].minor.yy407.value; } +{ yygotominor.yy372 = (yymsp[-1].minor.yy372 & yymsp[0].minor.yy407.mask) | yymsp[0].minor.yy407.value; } #line 2222 "parse.c" break; case 63: #line 209 "parse.y" -{ yygotominor.yy407.value = 0; yygotominor.yy407.tqmask = 0x000000; } +{ yygotominor.yy407.value = 0; yygotominor.yy407.mask = 0x000000; } #line 2227 "parse.c" /* No destructor defined for MATCH */ /* No destructor defined for nm */ break; case 64: #line 210 "parse.y" -{ yygotominor.yy407.value = yymsp[0].minor.yy372; yygotominor.yy407.tqmask = 0x0000ff; } +{ yygotominor.yy407.value = yymsp[0].minor.yy372; yygotominor.yy407.mask = 0x0000ff; } #line 2234 "parse.c" /* No destructor defined for ON */ /* No destructor defined for DELETE */ break; case 65: #line 211 "parse.y" -{ yygotominor.yy407.value = yymsp[0].minor.yy372<<8; yygotominor.yy407.tqmask = 0x00ff00; } +{ yygotominor.yy407.value = yymsp[0].minor.yy372<<8; yygotominor.yy407.mask = 0x00ff00; } #line 2241 "parse.c" /* No destructor defined for ON */ /* No destructor defined for UPDATE */ break; case 66: #line 212 "parse.y" -{ yygotominor.yy407.value = yymsp[0].minor.yy372<<16; yygotominor.yy407.tqmask = 0xff0000; } +{ yygotominor.yy407.value = yymsp[0].minor.yy372<<16; yygotominor.yy407.mask = 0xff0000; } #line 2248 "parse.c" /* No destructor defined for ON */ /* No destructor defined for INSERT */ diff --git a/kexi/3rdparty/kexisql/src/parse.y b/kexi/3rdparty/kexisql/src/parse.y index ad0f3716..29bb493b 100644 --- a/kexi/3rdparty/kexisql/src/parse.y +++ b/kexi/3rdparty/kexisql/src/parse.y @@ -193,12 +193,12 @@ ccons ::= COLLATE id(C). { // %type refargs {int} refargs(A) ::= . { A = OE_Restrict * 0x010101; } -refargs(A) ::= refargs(X) refarg(Y). { A = (X & Y.tqmask) | Y.value; } -%type refarg {struct {int value; int tqmask;}} -refarg(A) ::= MATCH nm. { A.value = 0; A.tqmask = 0x000000; } -refarg(A) ::= ON DELETE refact(X). { A.value = X; A.tqmask = 0x0000ff; } -refarg(A) ::= ON UPDATE refact(X). { A.value = X<<8; A.tqmask = 0x00ff00; } -refarg(A) ::= ON INSERT refact(X). { A.value = X<<16; A.tqmask = 0xff0000; } +refargs(A) ::= refargs(X) refarg(Y). { A = (X & Y.mask) | Y.value; } +%type refarg {struct {int value; int mask;}} +refarg(A) ::= MATCH nm. { A.value = 0; A.mask = 0x000000; } +refarg(A) ::= ON DELETE refact(X). { A.value = X; A.mask = 0x0000ff; } +refarg(A) ::= ON UPDATE refact(X). { A.value = X<<8; A.mask = 0x00ff00; } +refarg(A) ::= ON INSERT refact(X). { A.value = X<<16; A.mask = 0xff0000; } %type refact {int} refact(A) ::= SET NULL. { A = OE_SetNull; } refact(A) ::= SET DEFAULT. { A = OE_SetDflt; } diff --git a/kexi/3rdparty/kexisql/src/pragma.c b/kexi/3rdparty/kexisql/src/pragma.c index 7b100a70..4f102657 100644 --- a/kexi/3rdparty/kexisql/src/pragma.c +++ b/kexi/3rdparty/kexisql/src/pragma.c @@ -114,7 +114,7 @@ static int changeTempStorage(Parse *pParse, const char *zStorageType){ static int flagPragma(Parse *pParse, const char *zLeft, const char *zRight){ static const struct { const char *zName; /* Name of the pragma */ - int tqmask; /* Mask for the db->flags value */ + int mask; /* Mask for the db->flags value */ } aPragma[] = { { "vdbe_trace", SQLITE_VdbeTrace }, { "full_column_names", SQLITE_FullColNames }, @@ -131,13 +131,13 @@ static int flagPragma(Parse *pParse, const char *zLeft, const char *zRight){ if( strcmp(zLeft,zRight)==0 && (v = sqliteGetVdbe(pParse))!=0 ){ sqliteVdbeOp3(v, OP_ColumnName, 0, 1, aPragma[i].zName, P3_STATIC); sqliteVdbeOp3(v, OP_ColumnName, 1, 0, "boolean", P3_STATIC); - sqliteVdbeCode(v, OP_Integer, (db->flags & aPragma[i].tqmask)!=0, 0, + sqliteVdbeCode(v, OP_Integer, (db->flags & aPragma[i].mask)!=0, 0, OP_Callback, 1, 0, 0); }else if( getBoolean(zRight) ){ - db->flags |= aPragma[i].tqmask; + db->flags |= aPragma[i].mask; }else{ - db->flags &= ~aPragma[i].tqmask; + db->flags &= ~aPragma[i].mask; } return 1; } diff --git a/kexi/3rdparty/kexisql/src/select.c b/kexi/3rdparty/kexisql/src/select.c index 0dde6d2e..7ae02d33 100644 --- a/kexi/3rdparty/kexisql/src/select.c +++ b/kexi/3rdparty/kexisql/src/select.c @@ -1634,7 +1634,7 @@ substExprList(ExprList *pList, int iTable, ExprList *pEList){ */ static int flattenSubquery( Parse *pParse, /* The parsing context */ - Select *p, /* The tqparent or outer SELECT statement */ + Select *p, /* The parent or outer SELECT statement */ int iFrom, /* Index in p->pSrc->a[] of the inner subquery */ int isAgg, /* True if outer SELECT uses aggregate functions */ int subqueryIsAgg /* True if the subquery uses aggregate functions */ @@ -1987,8 +1987,8 @@ static int simpleMinMaxQuery(Parse *pParse, Select *p, int eDest, int iParm){ ** ** The pParent, parentTab, and *pParentAgg fields are filled in if this ** SELECT is a subquery. This routine may try to combine this SELECT -** with its tqparent to form a single flat query. In so doing, it might -** change the tqparent query from a non-aggregate to an aggregate query. +** with its parent to form a single flat query. In so doing, it might +** change the parent query from a non-aggregate to an aggregate query. ** For that reason, the pParentAgg flag is passed as a pointer, so it ** can be changed. ** @@ -2228,7 +2228,7 @@ int sqliteSelect( goto select_end; } - /* Check to see if this is a subquery that can be "flattened" into its tqparent. + /* Check to see if this is a subquery that can be "flattened" into its parent. ** If flattening is a possiblity, do so and return immediately. */ if( pParent && pParentAgg && @@ -2409,7 +2409,7 @@ int sqliteSelect( } /* If this was a subquery, we have now converted the subquery into a - ** temporary table. So delete the subquery structure from the tqparent + ** temporary table. So delete the subquery structure from the parent ** to prevent this subquery from being evaluated again and to force the ** the use of the temporary table. */ diff --git a/kexi/3rdparty/kexisql/src/sqliteInt.h b/kexi/3rdparty/kexisql/src/sqliteInt.h index ca5a85e9..3f8858e0 100644 --- a/kexi/3rdparty/kexisql/src/sqliteInt.h +++ b/kexi/3rdparty/kexisql/src/sqliteInt.h @@ -1053,9 +1053,9 @@ struct TriggerStep { * * struct TriggerStack has a "pNext" member, to allow linked lists to be * constructed. When coding nested triggers (triggers fired by other triggers) - * each nested trigger stores its tqparent trigger's TriggerStack as the "pNext" + * each nested trigger stores its parent trigger's TriggerStack as the "pNext" * pointer. Once the nested trigger has been coded, the pNext value is restored - * to the pTriggerStack member of the Parse stucture and coding of the tqparent + * to the pTriggerStack member of the Parse stucture and coding of the parent * trigger continues. * * Before a nested trigger is coded, the linked list pointed to by the diff --git a/kexi/3rdparty/kexisql/src/where.c b/kexi/3rdparty/kexisql/src/where.c index bb6a7f4f..714972f8 100644 --- a/kexi/3rdparty/kexisql/src/where.c +++ b/kexi/3rdparty/kexisql/src/where.c @@ -29,9 +29,9 @@ struct ExprInfo { ** p->pLeft is not the column of any table */ short int idxRight; /* p->pRight is a column in this table number. -1 if ** p->pRight is not the column of any table */ - unsigned prereqLeft; /* Bittqmask of tables referenced by p->pLeft */ - unsigned prereqRight; /* Bittqmask of tables referenced by p->pRight */ - unsigned prereqAll; /* Bittqmask of tables referenced by p */ + unsigned prereqLeft; /* Bitmask of tables referenced by p->pLeft */ + unsigned prereqRight; /* Bitmask of tables referenced by p->pRight */ + unsigned prereqAll; /* Bitmask of tables referenced by p */ }; /* @@ -81,12 +81,12 @@ static int exprSplit(int nSlot, ExprInfo *aSlot, Expr *pExpr){ } /* -** Initialize an expression tqmask set +** Initialize an expression mask set */ #define initMaskSet(P) memset(P, 0, sizeof(*P)) /* -** Return the bittqmask for the given cursor. Assign a new bittqmask +** Return the bitmask for the given cursor. Assign a new bitmask ** if this is the first time the cursor has been seen. */ static int getMask(ExprMaskSet *pMaskSet, int iCursor){ @@ -103,13 +103,13 @@ static int getMask(ExprMaskSet *pMaskSet, int iCursor){ } /* -** Destroy an expression tqmask set +** Destroy an expression mask set */ #define freeMaskSet(P) /* NO-OP */ /* ** This routine walks (recursively) an expression tree and generates -** a bittqmask indicating which tables are used in that expression +** a bitmask indicating which tables are used in that expression ** tree. ** ** In order for this routine to work, the calling function must have @@ -120,26 +120,26 @@ static int getMask(ExprMaskSet *pMaskSet, int iCursor){ ** the VDBE cursor number of the table. */ static int exprTableUsage(ExprMaskSet *pMaskSet, Expr *p){ - unsigned int tqmask = 0; + unsigned int mask = 0; if( p==0 ) return 0; if( p->op==TK_COLUMN ){ - tqmask = getMask(pMaskSet, p->iTable); - if( tqmask==0 ) tqmask = -1; - return tqmask; + mask = getMask(pMaskSet, p->iTable); + if( mask==0 ) mask = -1; + return mask; } if( p->pRight ){ - tqmask = exprTableUsage(pMaskSet, p->pRight); + mask = exprTableUsage(pMaskSet, p->pRight); } if( p->pLeft ){ - tqmask |= exprTableUsage(pMaskSet, p->pLeft); + mask |= exprTableUsage(pMaskSet, p->pLeft); } if( p->pList ){ int i; for(i=0; i<p->pList->nExpr; i++){ - tqmask |= exprTableUsage(pMaskSet, p->pList->a[i].pExpr); + mask |= exprTableUsage(pMaskSet, p->pList->a[i].pExpr); } } - return tqmask; + return mask; } /* @@ -391,7 +391,7 @@ WhereInfo *sqliteWhereBegin( int nExpr; /* Number of subexpressions in the WHERE clause */ int loopMask; /* One bit set for each outer loop */ int haveKey; /* True if KEY is on the stack */ - ExprMaskSet maskSet; /* The expression tqmask set */ + ExprMaskSet maskSet; /* The expression mask set */ int iDirectEq[32]; /* Term of the form ROWID==X for the N-th table */ int iDirectLt[32]; /* Term of the form ROWID<X or ROWID<=X */ int iDirectGt[32]; /* Term of the form ROWID>X or ROWID>=X */ @@ -448,16 +448,16 @@ WhereInfo *sqliteWhereBegin( if( pParse->trigStack ){ int x; if( (x = pParse->trigStack->newIdx) >= 0 ){ - int tqmask = ~getMask(&maskSet, x); - aExpr[i].prereqRight &= tqmask; - aExpr[i].prereqLeft &= tqmask; - aExpr[i].prereqAll &= tqmask; + int mask = ~getMask(&maskSet, x); + aExpr[i].prereqRight &= mask; + aExpr[i].prereqLeft &= mask; + aExpr[i].prereqAll &= mask; } if( (x = pParse->trigStack->oldIdx) >= 0 ){ - int tqmask = ~getMask(&maskSet, x); - aExpr[i].prereqRight &= tqmask; - aExpr[i].prereqLeft &= tqmask; - aExpr[i].prereqAll &= tqmask; + int mask = ~getMask(&maskSet, x); + aExpr[i].prereqRight &= mask; + aExpr[i].prereqLeft &= mask; + aExpr[i].prereqAll &= mask; } } } @@ -476,13 +476,13 @@ WhereInfo *sqliteWhereBegin( ** ** Actually, if there are more than 32 tables in the join, only the ** first 32 tables are candidates for indices. This is (again) due - ** to the limit of 32 bits in an integer bittqmask. + ** to the limit of 32 bits in an integer bitmask. */ loopMask = 0; for(i=0; i<pTabList->nSrc && i<ARRAYSIZE(iDirectEq); i++){ int j; int iCur = pTabList->a[i].iCursor; /* The cursor for this table */ - int tqmask = getMask(&maskSet, iCur); /* Cursor tqmask for this table */ + int mask = getMask(&maskSet, iCur); /* Cursor mask for this table */ Table *pTab = pTabList->a[i].pTab; Index *pIdx; Index *pBestIdx = 0; @@ -524,7 +524,7 @@ WhereInfo *sqliteWhereBegin( } } if( iDirectEq[i]>=0 ){ - loopMask |= tqmask; + loopMask |= mask; pWInfo->a[i].pIdx = 0; continue; } @@ -651,7 +651,7 @@ WhereInfo *sqliteWhereBegin( pWInfo->a[i].pIdx = pBestIdx; pWInfo->a[i].score = bestScore; pWInfo->a[i].bRev = 0; - loopMask |= tqmask; + loopMask |= mask; if( pBestIdx ){ pWInfo->a[i].iCur = pParse->nTab++; pWInfo->peakNTab = pParse->nTab; diff --git a/kexi/3rdparty/kexisql/tool/lemon.c b/kexi/3rdparty/kexisql/tool/lemon.c index a0eef810..b801e6b3 100644 --- a/kexi/3rdparty/kexisql/tool/lemon.c +++ b/kexi/3rdparty/kexisql/tool/lemon.c @@ -2542,10 +2542,10 @@ struct lemon *lemp; /* Search for the file "name" which is in the same directory as ** the exacutable */ -PRIVATE char *pathsearch(argv0,name,modetqmask) +PRIVATE char *pathsearch(argv0,name,modemask) char *argv0; char *name; -int modetqmask; +int modemask; { char *pathlist; char *path,*cp; @@ -2578,7 +2578,7 @@ int modetqmask; *cp = c; if( c==0 ) pathlist = ""; else pathlist = &cp[1]; - if( access(path,modetqmask)==0 ) break; + if( access(path,modemask)==0 ) break; } } } |