mirror of
https://github.com/apache/datafusion-sqlparser-rs.git
synced 2025-10-13 15:32:03 +00:00
Remove Box<> from SQLOrderByExpr
It was probably copied from somewhere else when most types were variants in ASTNode, and needed Box<> to prevent recursion in the ASTNode definition.
This commit is contained in:
parent
9967031cba
commit
3619e89e9c
3 changed files with 7 additions and 13 deletions
|
@ -242,15 +242,15 @@ fn parse_select_order_by() {
|
|||
assert_eq!(
|
||||
Some(vec![
|
||||
SQLOrderByExpr {
|
||||
expr: Box::new(ASTNode::SQLIdentifier("lname".to_string())),
|
||||
expr: ASTNode::SQLIdentifier("lname".to_string()),
|
||||
asc: Some(true),
|
||||
},
|
||||
SQLOrderByExpr {
|
||||
expr: Box::new(ASTNode::SQLIdentifier("fname".to_string())),
|
||||
expr: ASTNode::SQLIdentifier("fname".to_string()),
|
||||
asc: Some(false),
|
||||
},
|
||||
SQLOrderByExpr {
|
||||
expr: Box::new(ASTNode::SQLIdentifier("id".to_string())),
|
||||
expr: ASTNode::SQLIdentifier("id".to_string()),
|
||||
asc: None,
|
||||
},
|
||||
]),
|
||||
|
@ -277,11 +277,11 @@ fn parse_select_order_by_limit() {
|
|||
assert_eq!(
|
||||
Some(vec![
|
||||
SQLOrderByExpr {
|
||||
expr: Box::new(ASTNode::SQLIdentifier("lname".to_string())),
|
||||
expr: ASTNode::SQLIdentifier("lname".to_string()),
|
||||
asc: Some(true),
|
||||
},
|
||||
SQLOrderByExpr {
|
||||
expr: Box::new(ASTNode::SQLIdentifier("fname".to_string())),
|
||||
expr: ASTNode::SQLIdentifier("fname".to_string()),
|
||||
asc: Some(false),
|
||||
},
|
||||
]),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue