Abandon support for clang

The inconsistencies in clang's handling of casts was bad enough, and its
silliness with certain extensions, but discovering that it doesn't
support raw strings was just too much. Yes, it gives a 3s boost to qfvis
on gmsp3v2.bsp, but it's not worth the hassle.
This commit is contained in:
Bill Currie 2022-10-16 18:02:25 +09:00
parent 31dd419fde
commit 0c54b0652b
6 changed files with 1 additions and 16 deletions

View file

@ -29,12 +29,6 @@
#include <stdlib.h>
#ifdef __clang__
#define DESIGNATED_INIT
#else
#define DESIGNATED_INIT __attribute__((designated_init))
#endif
struct exprval_s;
struct exprctx_s;
struct va_ctx_s;
@ -63,7 +57,7 @@ typedef struct exprtype_s {
binop_t *binops;
unop_t *unops;
void *data;
} DESIGNATED_INIT exprtype_t;
} __attribute__((designated_init)) exprtype_t;
typedef struct exprval_s {
exprtype_t *type;

View file

@ -1782,7 +1782,6 @@ op_call:
}
}
exit_program:
(void)0;//FIXME for clang
}
#define MM(type) (*((pr_##type##_t *) (mm)))
@ -1802,7 +1801,6 @@ pr_address_mode (progs_t *pr, const dstatement_t *st, int mm_ind)
break;
case 1:
// entity.field (equivalent to OP_LOAD_t_v6p)
(void)0;//FIXME for clang
pr_ptr_t edict_area = pr->pr_edict_area - pr->pr_globals;
mm_offs = edict_area + OPA(entity) + OPB(field);
break;
@ -1840,7 +1838,6 @@ pr_call_mode (progs_t *pr, const dstatement_t *st, int mm_ind)
break;
case 4:
// entity.field (equivalent to OP_LOAD_t_v6p)
(void)0;//FIXME for clang
pr_ptr_t edict_area = pr->pr_edict_area - pr->pr_globals;
mm_offs = edict_area + OPA(entity) + OPB(field);
break;
@ -2535,7 +2532,6 @@ pr_exec_ruamoko (progs_t *pr, int exitdepth)
break;
OP_cmp_T (LT, U, long, lvec2, lvec4, <, ulong, ulvec2, ulvec4);
case OP_RETURN:
(void)0;//FIXME for clang
int ret_size = (st->c & 0x1f) + 1; // up to 32 words
if (st->c != 0xffff) {
mm = pr_address_mode (pr, st, st->c >> 5);
@ -2866,7 +2862,6 @@ pr_exec_ruamoko (progs_t *pr, int exitdepth)
}
}
exit_program:
(void)0;//FIXME for clang
}
/*
PR_ExecuteProgram

View file

@ -231,7 +231,6 @@ ED_ParseEpair (progs_t *pr, pr_type_t *base, pr_def_t *key, const char *s)
break;
case ev_vector:
(void)0;//FIXME for clang
vec3_t vec = {};
char *str = alloca (strlen (s) + 1);
strcpy (str, s);

View file

@ -1056,7 +1056,6 @@ fmt_state_conversion (fmt_state_t *state)
switch ((conv = *state->c++)) {
case '@':
// object
(void)0;// silly clang
pr_ptr_t at_param = P_UINT (pr, state->fmt_count);
if (state->at_handler) {
const char *at_str = state->at_handler (pr, at_param,

View file

@ -44,7 +44,6 @@ test_debug_handler (prdebug_t event, void *param, void *data)
case prd_subexit:
break;
case prd_trace:
(void)0;//FIXME for clang
dstatement_t *st = test_pr.pr_statements + test_pr.pr_xstatement;
if (verbose > 1) {
printf ("---\n");

View file

@ -532,7 +532,6 @@ create_light_matrices (lightingctx_t *lctx)
break;
case ST_CASCADE:
case ST_PLANE:
(void)0;//FIXME for clang
//FIXME will fail for -ref_direction
vec4f_t dir = light->direction;
dir[3] = 0;