diff options
author | Cyrill Gorcunov <gorcunov@gmail.com> | 2013-12-10 11:09:49 +0400 |
---|---|---|
committer | Cyrill Gorcunov <gorcunov@gmail.com> | 2013-12-10 11:10:19 +0400 |
commit | d578b511c936f35468f8c783db1237982ce3c0e1 (patch) | |
tree | 33172b23e6d86076949b5fdea6b3daab43f6794f /iflag.h | |
parent | f8d12d5011f16730da919b437e245a80b7054683 (diff) | |
download | nasm-d578b511c936f35468f8c783db1237982ce3c0e1.tar.gz nasm-d578b511c936f35468f8c783db1237982ce3c0e1.tar.bz2 nasm-d578b511c936f35468f8c783db1237982ce3c0e1.zip |
iflag: Don't use c99 array initialization
It's sad but not all compilers support c99 features, so drop
off IFLAG_INIT helper.
Reported-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Diffstat (limited to 'iflag.h')
-rw-r--r-- | iflag.h | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -13,8 +13,6 @@ int ilog2_32(uint32_t v); #define IF_GENBIT(bit) (UINT32_C(1) << (bit)) -#define IFLAG_INIT (iflag_t){ .field = { 0 }, } - static inline unsigned int iflag_test(const iflag_t *f, unsigned int bit) { unsigned int index = bit / 32; @@ -145,7 +143,9 @@ static inline int iflag_cmp_cpu_level(const iflag_t *a, const iflag_t *b) static inline iflag_t _iflag_pfmask(const iflag_t *a) { - iflag_t r = IFLAG_INIT; + iflag_t r; + + iflag_clear_all(&r); if (iflag_test(a, IF_CYRIX)) iflag_set(&r, IF_CYRIX); |