DEADSOFTWARE

Исправлена проверка VAR-параметров-записей
[dsw-obn.git] / src / oberon.c
index 72bf1c68b5a1f774c8284b4cab65a17c6adfc788..4a740d8130db2be573d6c197eadc2ee767244d3c 100644 (file)
@@ -2412,8 +2412,7 @@ oberon_proc_decl_body(oberon_context_t * ctx, oberon_object_t * proc)
                oberon_error(ctx, "procedure name not matched");
        }
 
-       if(proc -> type -> base -> class == OBERON_TYPE_NOTYPE
-               && proc -> has_return == 0)
+       if(proc -> type -> base -> class == OBERON_TYPE_NOTYPE)
        {
                oberon_make_return(ctx, NULL);
        }
@@ -4536,7 +4535,7 @@ oberon_make_ord_call(oberon_context_t * ctx, int num_args, oberon_expr_t * list_
        }
        else
        {
-               expr = oberon_cast_expr(ctx, arg, ctx -> int_type);
+               expr = oberon_cast_expr(ctx, arg, ctx -> shortint_type);
        }
        return expr;
 }