mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-03-22 02:31:28 +00:00
-fsingle-vector-defs to disable _x,_y,_z generation
This commit is contained in:
parent
116d744823
commit
d09ab90f24
3 changed files with 8 additions and 2 deletions
|
@ -251,3 +251,8 @@ Produce a linenumber file along with the output .dat file.
|
|||
Use C's operator precedence for ternary expressions. Unless your code
|
||||
depends on fteqcc-compatible behaviour, you'll want to use thi
|
||||
soption.
|
||||
.TP
|
||||
.B -fsingle-vector-defs
|
||||
Normally vectors generate 4 defs, once for the vector, and once for
|
||||
its components with _x, _y, _z suffixes. This option
|
||||
prevents components from being listed.
|
||||
|
|
4
ir.c
4
ir.c
|
@ -3152,7 +3152,7 @@ static void gen_vector_defs(prog_section_def def, const char *name)
|
|||
char *component;
|
||||
size_t len, i;
|
||||
|
||||
if (!name)
|
||||
if (!name || OPTS_FLAG(SINGLE_VECTOR_DEFS))
|
||||
return;
|
||||
|
||||
len = strlen(name);
|
||||
|
@ -3178,7 +3178,7 @@ static void gen_vector_fields(prog_section_field fld, const char *name)
|
|||
char *component;
|
||||
size_t len, i;
|
||||
|
||||
if (!name)
|
||||
if (!name || OPTS_FLAG(SINGLE_VECTOR_DEFS))
|
||||
return;
|
||||
|
||||
len = strlen(name);
|
||||
|
|
1
opts.def
1
opts.def
|
@ -39,6 +39,7 @@
|
|||
GMQCC_DEFINE_FLAG(ASSIGN_FUNCTION_TYPES)
|
||||
GMQCC_DEFINE_FLAG(LNO)
|
||||
GMQCC_DEFINE_FLAG(CORRECT_TERNARY)
|
||||
GMQCC_DEFINE_FLAG(SINGLE_VECTOR_DEFS)
|
||||
#endif
|
||||
|
||||
/* warning flags */
|
||||
|
|
Loading…
Reference in a new issue