]> git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - parser.cpp
Just mark LOCAL_RETURN noref instead of checking for '#' in the name
[xonotic/gmqcc.git] / parser.cpp
index ed5bde108bff5e2455a563bac41fb8db8b649e98..e365316f33068520e62e684be39d97aa9fb0f47b 100644 (file)
@@ -2630,6 +2630,7 @@ static bool parse_return(parser_t *parser, ast_block *block, ast_expression **ou
             retval = new ast_value(ctx, "#LOCAL_RETURN", TYPE_VOID);
             retval->adoptType(*expected->m_next);
             parser->function->m_return_value = retval;
+            parser->function->m_return_value->m_flags |= AST_FLAG_NOREF;
         }
 
         if (!exp->compareType(*retval)) {