From 09a487eb2b2bcabeaeec8d2c7ca422993df0efb5 Mon Sep 17 00:00:00 2001 From: grischka Date: Sat, 1 Oct 2016 20:04:58 +0200 Subject: libtcc: cleanup -x switch code Abusing filename[0] as type is just too much of a hack. -- From 05364072042ff37904a7b0b14cdd85a1ea1ca11d --- tcc.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'tcc.h') diff --git a/tcc.h b/tcc.h index cfff7cf..42088e1 100644 --- a/tcc.h +++ b/tcc.h @@ -850,7 +850,7 @@ struct TCCState { #endif /* used by main and tcc_parse_args only */ - char **files; /* files seen on command line */ + struct filespec **files; /* files seen on command line */ int nb_files; /* number thereof */ int nb_libraries; /* number of libs thereof */ char *outfile; /* output filename */ @@ -863,6 +863,10 @@ struct TCCState { ParseArgsState *parse_args_state; }; +struct filespec { + char type, name[1]; +}; + /* The current value can be: */ #define VT_VALMASK 0x003f /* mask for value location, register or: */ #define VT_CONST 0x0030 /* constant in vc (must be first non register value) */ -- cgit v1.3.1