@@ -482,59 +482,32 @@ pub fn VirtualTable(comptime Table: type) type {
482482 return struct {
483483 const Self = @This ();
484484
485- pub const module = if (versionGreaterThanOrEqualTo (3 , 26 , 0 ))
486- c.sqlite3_module {
487- .iVersion = 3 ,
488- .xCreate = if (tableHasDecl ("create" )) Creatable .xCreate else null ,
489- .xConnect = xConnect ,
490- .xBestIndex = xBestIndex ,
491- .xDisconnect = xDisconnect ,
492- .xDestroy = if (tableHasDecl ("destroy" )) Creatable .xDestroy else xDisconnect ,
493- .xOpen = xOpen ,
494- .xClose = xClose ,
495- .xFilter = xFilter ,
496- .xNext = xNext ,
497- .xEof = xEof ,
498- .xColumn = xColumn ,
499- .xRowid = xRowid ,
500- .xUpdate = if (tableHasDecl ("update" )) Writeable .xUpdate else null ,
501- .xBegin = if (tableHasDecl ("begin" )) Transactable .xBegin else null ,
502- .xSync = if (tableHasDecl ("sync" )) Transactable .xSync else null ,
503- .xCommit = if (tableHasDecl ("commit" )) Transactable .xCommit else null ,
504- .xRollback = if (tableHasDecl ("rollback" )) Transactable .xRollback else null ,
505- .xFindFunction = null ,
506- .xRename = null ,
507- .xSavepoint = if (tableHasDecl ("savepoint" )) Transactable .xSavepoint else null ,
508- .xRelease = if (tableHasDecl ("release" )) Transactable .xRelease else null ,
509- .xRollbackTo = if (tableHasDecl ("rollbackTo" )) Transactable .xRollbackTo else null ,
510- .xShadowName = if (tableHasDecl ("isShadowName" )) HasShadowTables .xShadowName else null ,
511- }
512- else
513- c.sqlite3_module {
514- .iVersion = 2 ,
515- .xCreate = if (tableHasDecl ("create" )) Creatable .xCreate else null ,
516- .xConnect = xConnect ,
517- .xBestIndex = xBestIndex ,
518- .xDisconnect = xDisconnect ,
519- .xDestroy = if (tableHasDecl ("destroy" )) Creatable .xDestroy else xDisconnect ,
520- .xOpen = xOpen ,
521- .xClose = xClose ,
522- .xFilter = xFilter ,
523- .xNext = xNext ,
524- .xEof = xEof ,
525- .xColumn = xColumn ,
526- .xRowid = xRowid ,
527- .xUpdate = if (tableHasDecl ("update" )) Writeable .xUpdate else null ,
528- .xBegin = if (tableHasDecl ("begin" )) Transactable .xBegin else null ,
529- .xSync = if (tableHasDecl ("sync" )) Transactable .xSync else null ,
530- .xCommit = if (tableHasDecl ("commit" )) Transactable .xCommit else null ,
531- .xRollback = if (tableHasDecl ("rollback" )) Transactable .xRollback else null ,
532- .xFindFunction = null ,
533- .xRename = null ,
534- .xSavepoint = if (tableHasDecl ("savepoint" )) Transactable .xSavepoint else null ,
535- .xRelease = if (tableHasDecl ("release" )) Transactable .xRelease else null ,
536- .xRollbackTo = if (tableHasDecl ("rollbackTo" )) Transactable .xRollbackTo else null ,
537- };
485+ pub const module = c.sqlite3_module {
486+ .iVersion = 3 ,
487+ .xCreate = if (tableHasDecl ("create" )) Creatable .xCreate else null ,
488+ .xConnect = xConnect ,
489+ .xBestIndex = xBestIndex ,
490+ .xDisconnect = xDisconnect ,
491+ .xDestroy = if (tableHasDecl ("destroy" )) Creatable .xDestroy else xDisconnect ,
492+ .xOpen = xOpen ,
493+ .xClose = xClose ,
494+ .xFilter = xFilter ,
495+ .xNext = xNext ,
496+ .xEof = xEof ,
497+ .xColumn = xColumn ,
498+ .xRowid = xRowid ,
499+ .xUpdate = if (tableHasDecl ("update" )) Writeable .xUpdate else null ,
500+ .xBegin = if (tableHasDecl ("begin" )) Transactable .xBegin else null ,
501+ .xSync = if (tableHasDecl ("sync" )) Transactable .xSync else null ,
502+ .xCommit = if (tableHasDecl ("commit" )) Transactable .xCommit else null ,
503+ .xRollback = if (tableHasDecl ("rollback" )) Transactable .xRollback else null ,
504+ .xFindFunction = null ,
505+ .xRename = null ,
506+ .xSavepoint = if (tableHasDecl ("savepoint" )) Transactable .xSavepoint else null ,
507+ .xRelease = if (tableHasDecl ("release" )) Transactable .xRelease else null ,
508+ .xRollbackTo = if (tableHasDecl ("rollbackTo" )) Transactable .xRollbackTo else null ,
509+ .xShadowName = if (tableHasDecl ("isShadowName" )) HasShadowTables .xShadowName else null ,
510+ };
538511
539512 const table_decls = switch (@typeInfo (Table )) {
540513 .Struct = > | table_struct | table_struct .decls ,
0 commit comments