Add a test case for the uninit temp in HUD.r

This commit is contained in:
Bill Currie 2020-02-15 19:42:32 +09:00
parent 7bfa0f7a92
commit 9c996df7b4
2 changed files with 36 additions and 0 deletions

View file

@ -41,6 +41,7 @@ test_progs_dat=\
func-expr.dat \
func-static.dat \
infloop.dat \
ivar-struct-return.dat \
modulo.dat \
paramret.dat \
quaternion.dat \
@ -236,6 +237,15 @@ infloop.run: Makefile build-run
include ./$(DEPDIR)/infloop.Qo # am--include-marker
r_depfiles_remade += ./$(DEPDIR)/infloop.Qo
ivar_struct_return_dat_SOURCES=ivar-struct-return.r
ivar_struct_return_obj=$(ivar_struct_return_dat_SOURCES:.r=.qfo)
ivar-struct-return.dat$(EXEEXT): $(ivar_struct_return_obj) $(QFCC_DEP)
$(QFCC) $(QCFLAGS) -o $@ $(ivar_struct_return_obj)
ivar-struct-return.run: Makefile build-run
$(srcdir)/build-run $@
include ./$(DEPDIR)/ivar-struct-return.Qo # am--include-marker
r_depfiles_remade += ./$(DEPDIR)/ivar-struct-return.Qo
modulo_dat_SOURCES=modulo.r
modulo_obj=$(modulo_dat_SOURCES:.r=.qfo)
modulo.dat$(EXEEXT): $(modulo_obj) $(QFCC_DEP)

View file

@ -0,0 +1,26 @@
#pragma bug die
struct Point {
int x;
int y;
};
typedef struct Point Point;
@interface Object
{
Point origin;
}
-(Point) origin;
@end
@implementation Object
-(Point) origin
{
return origin;
}
@end
void __obj_exec_class (struct obj_module *msg) = #0;
int main()
{
return 0; // to survive and prevail
}