Consistently use __typeof__() rather than typeof() or __typeof() for compatibility (GCC and clang and, perhaps, other future compilers) irrespective of -std= compilation options.

This commit is contained in:
Richard Frith-Macdonald 2020-12-15 13:01:00 +00:00
parent 5026274f6c
commit 6d20773f56
11 changed files with 30 additions and 30 deletions

View file

@ -101,7 +101,7 @@ typedef GSIMapNode_t *GSIMapNode;
pointerFunctionsAssign(&M->cb.pf, (void**)addr, (x).obj);
#define GSI_MAP_READ_KEY(M,addr) \
(M->legacy ? *(addr) :\
(typeof(*addr))pointerFunctionsRead(&M->cb.pf, (void**)addr))
(__typeof__(*addr))pointerFunctionsRead(&M->cb.pf, (void**)addr))
#define GSI_MAP_ENUMERATOR NSHashEnumerator