diff --git a/vlib/v/gen/sql.v b/vlib/v/gen/sql.v index 52fd707836..d7525d2865 100644 --- a/vlib/v/gen/sql.v +++ b/vlib/v/gen/sql.v @@ -206,6 +206,12 @@ fn (mut g Gen) expr_to_sql(expr ast.Expr) { g.inc_sql_i() g.sql_bind_int(it.val) } + ast.BoolLiteral { + // true/false literals were added to Sqlite 3.23 (2018-04-02) + // but lots of apps/distros use older sqlite (e.g. Ubuntu 18.04 LTS ) + g.inc_sql_i() + g.sql_bind_int(if it.val { '1' } else { '0' }) + } ast.Ident { // `name == user_name` => `name == ?1` // for left sides just add a string, for right sides, generate the bindings diff --git a/vlib/v/parser/comptime.v b/vlib/v/parser/comptime.v index e47caca449..09ed5bf503 100644 --- a/vlib/v/parser/comptime.v +++ b/vlib/v/parser/comptime.v @@ -100,9 +100,9 @@ fn (mut p Parser) vweb() ast.ComptimeCall { } // println('path is now "$path"') } - // if p.pref.is_verbose { - println('>>> compiling vweb HTML template "$path"') - // } + if p.pref.is_verbose { + println('>>> compiling vweb HTML template "$path"') + } v_code := tmpl.compile_file(path, p.cur_fn_name) mut scope := &ast.Scope{ start_pos: 0