@@ -268,6 +268,8 @@ extension CompilerWithSource: StmtSyntaxVisitor {
268268 mutating func visit( _ stmt: SavepointStmtSyntax ) -> ( Statement , Diagnostics ) ? { nil }
269269
270270 mutating func visit( _ stmt: ReleaseStmtSyntax ) -> ( Statement , Diagnostics ) ? { nil }
271+
272+ mutating func visit( _ stmt: VacuumStmtSyntax ) -> ( Statement , Diagnostics ) ? { nil }
271273}
272274
273275/// Used to validate whether a statement syntax is valid for use in migrations
@@ -295,6 +297,7 @@ struct IsValidForMigrations: StmtSyntaxVisitor {
295297 func visit( _ stmt: RollbackStmtSyntax ) -> Bool { false }
296298 func visit( _ stmt: SavepointStmtSyntax ) -> Bool { false }
297299 func visit( _ stmt: ReleaseStmtSyntax ) -> Bool { false }
300+ func visit( _ stmt: VacuumStmtSyntax ) -> Bool { true }
298301}
299302
300303/// Used to validate whether a statement syntax is valid for use in queries
@@ -322,6 +325,7 @@ struct IsValidForQueries: StmtSyntaxVisitor {
322325 func visit( _ stmt: RollbackStmtSyntax ) -> Bool { false }
323326 func visit( _ stmt: SavepointStmtSyntax ) -> Bool { false }
324327 func visit( _ stmt: ReleaseStmtSyntax ) -> Bool { false }
328+ func visit( _ stmt: VacuumStmtSyntax ) -> Bool { false }
325329}
326330
327331// Mainly used in tests, since they are usually a mix of migrations and queries
@@ -349,4 +353,5 @@ struct IsAlwaysValid: StmtSyntaxVisitor {
349353 func visit( _ stmt: RollbackStmtSyntax ) -> Bool { true }
350354 func visit( _ stmt: SavepointStmtSyntax ) -> Bool { true }
351355 func visit( _ stmt: ReleaseStmtSyntax ) -> Bool { true }
356+ func visit( _ stmt: VacuumStmtSyntax ) -> Bool { true }
352357}
0 commit comments