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

compiler: map[string]pointer, ?pointer, fix []pointer

This commit is contained in:
れもん
2019-12-22 07:44:16 +09:00
committed by Alexander Medvednikov
parent b76227b781
commit 28ecfb231d
14 changed files with 98 additions and 48 deletions

View File

@ -215,7 +215,7 @@ fn (p mut Parser) if_statement(is_expr bool, elif_depth int) string {
p.error('`if x := opt() {` syntax requires a function that returns an optional value')
}
p.is_var_decl = false
typ := option_type[7..]
typ := parse_pointer(option_type[7..])
// Option_User tmp = get_user(1);
// if (tmp.ok) {
// User user = *(User*)tmp.data;