mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
checker: allow using struct field as ORM limit and offset. (#17330)
This commit is contained in:
@@ -348,6 +348,10 @@ fn (mut c Checker) check_sql_expr_type_is_int(expr &ast.Expr, sql_keyword string
|
||||
if expr.obj.typ.is_int() {
|
||||
return
|
||||
}
|
||||
} else if expr is ast.SelectorExpr {
|
||||
if expr.typ.is_int() {
|
||||
return
|
||||
}
|
||||
} else if expr is ast.CallExpr {
|
||||
if expr.return_type == 0 {
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user