Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(80)

Side by Side Diff: third_party/sqlite/src/src/test_schema.c

Issue 2751253002: [sql] Import SQLite 3.17.0. (Closed)
Patch Set: also clang on Linux i386 Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/sqlite/src/src/test_rtree.c ('k') | third_party/sqlite/src/src/test_sqllog.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 ** 2006 June 10 2 ** 2006 June 10
3 ** 3 **
4 ** The author disclaims copyright to this source code. In place of 4 ** The author disclaims copyright to this source code. In place of
5 ** a legal notice, here is a blessing: 5 ** a legal notice, here is a blessing:
6 ** 6 **
7 ** May you do good and not evil. 7 ** May you do good and not evil.
8 ** May you find forgiveness for yourself and forgive others. 8 ** May you find forgiveness for yourself and forgive others.
9 ** May you share freely, never taking more than you give. 9 ** May you share freely, never taking more than you give.
10 ** 10 **
(...skipping 17 matching lines...) Expand all
28 "not_null," /* Boolean. True if NOT NULL was specified */ \ 28 "not_null," /* Boolean. True if NOT NULL was specified */ \
29 "dflt_value," /* Default value for this column */ \ 29 "dflt_value," /* Default value for this column */ \
30 "pk" /* True if this column is part of the primary key */ \ 30 "pk" /* True if this column is part of the primary key */ \
31 ")" 31 ")"
32 32
33 /* If SQLITE_TEST is defined this code is preprocessed for use as part 33 /* If SQLITE_TEST is defined this code is preprocessed for use as part
34 ** of the sqlite test binary "testfixture". Otherwise it is preprocessed 34 ** of the sqlite test binary "testfixture". Otherwise it is preprocessed
35 ** to be compiled into an sqlite dynamic extension. 35 ** to be compiled into an sqlite dynamic extension.
36 */ 36 */
37 #ifdef SQLITE_TEST 37 #ifdef SQLITE_TEST
38 #include "sqliteInt.h" 38 # include "sqliteInt.h"
39 #include "tcl.h" 39 # if defined(INCLUDE_SQLITE_TCL_H)
40 # include "sqlite_tcl.h"
41 # else
42 # include "tcl.h"
43 # endif
40 #else 44 #else
41 #include "sqlite3ext.h" 45 # include "sqlite3ext.h"
42 SQLITE_EXTENSION_INIT1 46 SQLITE_EXTENSION_INIT1
43 #endif 47 #endif
44 48
45 #include <stdlib.h> 49 #include <stdlib.h>
46 #include <string.h> 50 #include <string.h>
47 #include <assert.h> 51 #include <assert.h>
48 52
49 typedef struct schema_vtab schema_vtab; 53 typedef struct schema_vtab schema_vtab;
50 typedef struct schema_cursor schema_cursor; 54 typedef struct schema_cursor schema_cursor;
51 55
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
295 #ifdef SQLITE_TEST 299 #ifdef SQLITE_TEST
296 300
297 /* 301 /*
298 ** Decode a pointer to an sqlite3 object. 302 ** Decode a pointer to an sqlite3 object.
299 */ 303 */
300 extern int getDbPointer(Tcl_Interp *interp, const char *zA, sqlite3 **ppDb); 304 extern int getDbPointer(Tcl_Interp *interp, const char *zA, sqlite3 **ppDb);
301 305
302 /* 306 /*
303 ** Register the schema virtual table module. 307 ** Register the schema virtual table module.
304 */ 308 */
305 static int register_schema_module( 309 static int SQLITE_TCLAPI register_schema_module(
306 ClientData clientData, /* Not used */ 310 ClientData clientData, /* Not used */
307 Tcl_Interp *interp, /* The TCL interpreter that invoked this command */ 311 Tcl_Interp *interp, /* The TCL interpreter that invoked this command */
308 int objc, /* Number of arguments */ 312 int objc, /* Number of arguments */
309 Tcl_Obj *CONST objv[] /* Command arguments */ 313 Tcl_Obj *CONST objv[] /* Command arguments */
310 ){ 314 ){
311 sqlite3 *db; 315 sqlite3 *db;
312 if( objc!=2 ){ 316 if( objc!=2 ){
313 Tcl_WrongNumArgs(interp, 1, objv, "DB"); 317 Tcl_WrongNumArgs(interp, 1, objv, "DB");
314 return TCL_ERROR; 318 return TCL_ERROR;
315 } 319 }
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 const sqlite3_api_routines *pApi 357 const sqlite3_api_routines *pApi
354 ){ 358 ){
355 SQLITE_EXTENSION_INIT2(pApi); 359 SQLITE_EXTENSION_INIT2(pApi);
356 #ifndef SQLITE_OMIT_VIRTUALTABLE 360 #ifndef SQLITE_OMIT_VIRTUALTABLE
357 sqlite3_create_module(db, "schema", &schemaModule, 0); 361 sqlite3_create_module(db, "schema", &schemaModule, 0);
358 #endif 362 #endif
359 return 0; 363 return 0;
360 } 364 }
361 365
362 #endif 366 #endif
OLDNEW
« no previous file with comments | « third_party/sqlite/src/src/test_rtree.c ('k') | third_party/sqlite/src/src/test_sqllog.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698