mirror of
https://github.com/vlang/v.git
synced 2025-09-13 14:32:26 +03:00
tools: format most examples and tutorials, add them to v test-cleancode
(#9826)
This commit is contained in:
parent
dff50686d6
commit
16e79bc3ca
38 changed files with 471 additions and 433 deletions
|
@ -1,7 +1,7 @@
|
|||
import sqlite
|
||||
|
||||
fn main() {
|
||||
db := sqlite.connect(':memory:')?
|
||||
db := sqlite.connect(':memory:') ?
|
||||
db.exec("create table users (id integer primary key, name text default '');")
|
||||
|
||||
db.exec("insert into users (name) values ('Sam')")
|
||||
|
@ -15,7 +15,7 @@ fn main() {
|
|||
assert name == 'Sam'
|
||||
|
||||
users, code := db.exec('select * from users')
|
||||
println("SQL Result code: $code")
|
||||
println('SQL Result code: $code')
|
||||
for row in users {
|
||||
println(row.vals)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue