sqlite3-parser: box Following and Preceding in FrameBound

This commit is contained in:
Jussi Saurio
2025-02-08 18:07:38 +02:00
parent ac7f9d67b7
commit 7426204204
2 changed files with 4 additions and 4 deletions

View File

@@ -1872,9 +1872,9 @@ pub enum FrameBound {
/// `CURRENT ROW`
CurrentRow,
/// `FOLLOWING`
Following(Expr),
Following(Box<Expr>),
/// `PRECEDING`
Preceding(Expr),
Preceding(Box<Expr>),
/// `UNBOUNDED FOLLOWING`
UnboundedFollowing,
/// `UNBOUNDED PRECEDING`

View File

@@ -1454,9 +1454,9 @@ frame_bound_s(A) ::= UNBOUNDED PRECEDING. {A = FrameBound::UnboundedPreceding;}
frame_bound_e(A) ::= frame_bound(X). {A = X;}
frame_bound_e(A) ::= UNBOUNDED FOLLOWING. {A = FrameBound::UnboundedFollowing;}
frame_bound(A) ::= expr(X) PRECEDING. { A = FrameBound::Preceding(X); }
frame_bound(A) ::= expr(X) PRECEDING. { A = FrameBound::Preceding(Box::new(X)); }
frame_bound(A) ::= CURRENT ROW. { A = FrameBound::CurrentRow; }
frame_bound(A) ::= expr(X) FOLLOWING. { A = FrameBound::Following(X); }
frame_bound(A) ::= expr(X) FOLLOWING. { A = FrameBound::Following(Box::new(X)); }
%type frame_exclude_opt {Option<FrameExclude>}
frame_exclude_opt(A) ::= . {A = None;}