flag types defined as unions

The risc-v abi needs to know if a
type is defined as a union or not.

We cannot use nunion to obtain this
information because the risc-v abi
made the unfortunate decision of
treating

	union { int i; }

differently from

	int i;

So, instead, I introduce a single
bit flag 'isunion'.
This commit is contained in:
Quentin Carbonneaux 2022-03-08 15:49:01 +01:00
parent 349794f3e4
commit 9060981c10
5 changed files with 11 additions and 8 deletions

3
all.h
View file

@ -357,7 +357,8 @@ struct Fn {
struct Typ {
char name[NString];
int dark;
char isdark;
char isunion;
int align;
uint64_t size;
uint nunion;