mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
v: add map init
This commit is contained in:
@@ -530,7 +530,7 @@ pub fn (p mut Parser) name_expr() ast.Expr {
|
||||
// `map[string]int` initialization
|
||||
if p.tok.lit == 'map' && p.peek_tok.kind == .lsbr {
|
||||
map_type := p.parse_map_type()
|
||||
return ast.Type{
|
||||
return ast.MapInit {
|
||||
typ: map_type
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user