mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-11 01:42:22 +03:00
Improved comments. Add assert()s to verify that the AggInfo structure
is unchanged after registers have been assigned. FossilOrigin-Name: 5200b84195ee1ccaa387f7032eae3d463724c48cb53ba0251bbc79e927dd9752
This commit is contained in:
@@ -2766,10 +2766,15 @@ struct AggInfo {
|
||||
};
|
||||
|
||||
/*
|
||||
** Macros to compute aCol[] and aFunc[] register numbers:
|
||||
** Macros to compute aCol[] and aFunc[] register numbers.
|
||||
**
|
||||
** These macros should not be used prior to the call to
|
||||
** assignAggregateRegisters() that computes the value of pAggInfo->iFirstReg.
|
||||
** The assert()s that are part of this macro verify that constraint.
|
||||
*/
|
||||
#define AggInfoColumnReg(A,I) ((A)->iFirstReg+(I))
|
||||
#define AggInfoFuncReg(A,I) ((A)->iFirstReg+(A)->nColumn+(I))
|
||||
#define AggInfoColumnReg(A,I) (assert((A)->iFirstReg),(A)->iFirstReg+(I))
|
||||
#define AggInfoFuncReg(A,I) \
|
||||
(assert((A)->iFirstReg),(A)->iFirstReg+(A)->nColumn+(I))
|
||||
|
||||
/*
|
||||
** The datatype ynVar is a signed integer, either 16-bit or 32-bit.
|
||||
|
||||
Reference in New Issue
Block a user