mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
vfmt: no longer replace go
with spawn
This commit is contained in:
parent
786865d349
commit
f8422738bb
@ -112,7 +112,7 @@ fn (mut p Parser) check_expr(precedence int) !ast.Expr {
|
||||
}
|
||||
}
|
||||
.key_go, .key_spawn {
|
||||
if p.pref.use_coroutines && p.tok.kind == .key_go {
|
||||
if (p.pref.use_coroutines || p.pref.is_fmt) && p.tok.kind == .key_go {
|
||||
mut go_expr := p.go_expr()
|
||||
go_expr.is_expr = true
|
||||
node = go_expr
|
||||
|
@ -1078,7 +1078,7 @@ fn (mut p Parser) stmt(is_top_level bool) ast.Stmt {
|
||||
}
|
||||
}
|
||||
.key_go, .key_spawn {
|
||||
if p.pref.use_coroutines && p.tok.kind == .key_go {
|
||||
if (p.pref.use_coroutines || p.pref.is_fmt) && p.tok.kind == .key_go {
|
||||
go_expr := p.go_expr()
|
||||
return ast.ExprStmt{
|
||||
expr: go_expr
|
||||
|
Loading…
Reference in New Issue
Block a user