1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

Make sure KeyInfo objects on multi-column indices of WITHOUT ROWID tables

have the correct nField and nXField values.  Also, add the
SQLITE_ENABLE_MODULE_COMMENT compile-time option and the VdbeModuleComment()
macro and use it to label entry and exit points of some key routines.

FossilOrigin-Name: 6d9af6065fc0da8337aee2297a8da7511eecccf1
This commit is contained in:
drh
2013-10-30 15:52:32 +00:00
parent 5b843aa032
commit 72ffd09188
7 changed files with 32 additions and 13 deletions

View File

@@ -218,15 +218,27 @@ UnpackedRecord *sqlite3VdbeAllocUnpackedRecord(KeyInfo *, char *, int, char **);
void sqlite3VdbeLinkSubProgram(Vdbe *, SubProgram *);
#endif
/* Use SQLITE_ENABLE_COMMENTS to enable generation of extra comments on
** each VDBE opcode.
**
** Use the SQLITE_ENABLE_MODULE_COMMENTS macro to see some extra no-op
** comments in VDBE programs that show key decision points in the code
** generator.
*/
#ifdef SQLITE_ENABLE_EXPLAIN_COMMENTS
void sqlite3VdbeComment(Vdbe*, const char*, ...);
# define VdbeComment(X) sqlite3VdbeComment X
void sqlite3VdbeNoopComment(Vdbe*, const char*, ...);
# define VdbeNoopComment(X) sqlite3VdbeNoopComment X
# ifdef SQLITE_ENABLE_MODULE_COMMENTS
# define VdbeModuleComment(X) sqlite3VdbeNoopComment X
# else
# define VdbeModuleComment(X)
# endif
#else
# define VdbeComment(X)
# define VdbeNoopComment(X)
# define VdbeModuleComment(X)
#endif
#endif