parser: allow multi returns in high order fns

This commit is contained in:
joe-conigliaro 2019-10-10 04:55:36 +11:00 committed by Alexander Medvednikov
parent 236b34c009
commit febd532c4a
3 changed files with 31 additions and 18 deletions

View file

@ -937,7 +937,8 @@ fn (p mut Parser) get_type() string {
}
p.check(.rpar)
// p.inside_tuple = false
return '_V_MulRet_' + types.join('_V_').replace('*', '_PTR_')
typ = p.register_multi_return_stuct(types)
return typ
}
// fn type
if p.tok == .func {