mirror of
https://github.com/aljazceru/turso.git
synced 2026-01-21 00:54:19 +01:00
sqlite3-parser: separate boxed Delete struct
This commit is contained in:
@@ -761,14 +761,14 @@ limit_opt(A) ::= LIMIT expr(X) COMMA expr(Y).
|
||||
cmd ::= with(C) DELETE FROM xfullname(X) indexed_opt(I) where_opt_ret(W)
|
||||
orderby_opt(O) limit_opt(L). {
|
||||
let (where_clause, returning) = W;
|
||||
self.ctx.stmt = Some(Stmt::Delete{ with: C, tbl_name: X, indexed: I, where_clause: where_clause.map(Box::new), returning,
|
||||
order_by: O, limit: L });
|
||||
self.ctx.stmt = Some(Stmt::Delete(Box::new(Delete{ with: C, tbl_name: X, indexed: I, where_clause: where_clause.map(Box::new), returning,
|
||||
order_by: O, limit: L })));
|
||||
}
|
||||
%else
|
||||
cmd ::= with(C) DELETE FROM xfullname(X) indexed_opt(I) where_opt_ret(W). {
|
||||
let (where_clause, returning) = W;
|
||||
self.ctx.stmt = Some(Stmt::Delete{ with: C, tbl_name: X, indexed: I, where_clause: where_clause.map(Box::new), returning,
|
||||
order_by: None, limit: None });
|
||||
self.ctx.stmt = Some(Stmt::Delete(Box::new(Delete{ with: C, tbl_name: X, indexed: I, where_clause: where_clause.map(Box::new), returning,
|
||||
order_by: None, limit: None })));
|
||||
}
|
||||
%endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user