1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

small vfmt fixes

This commit is contained in:
Alexander Medvednikov
2019-12-22 01:27:03 +03:00
parent 749d3ec14d
commit b76227b781
4 changed files with 17 additions and 7 deletions

View File

@@ -586,6 +586,7 @@ fn (p mut Parser) parse(pass Pass) {
for i := start; i < end; i++ {
p.cgen.lines[i] = ''
}
p.fgen_nl()
}
else {
p.error('unexpected token `${p.strtok()}`')
@@ -793,6 +794,9 @@ fn (p mut Parser) type_decl() {
cat: .alias
is_public: is_pub
})
if p.tok != .key_type {
p.fspace()
}
}
// current token is `(`
@@ -980,7 +984,7 @@ fn (p mut Parser) get_type() string {
// Register anon fn type
fn_typ := Type{
name: f.typ_str() // 'fn (int, int) string'
mod: p.mod
func: f
}