mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
tests/sys_architecture: also test UWORD_MAX, ...
Also verify correct values for UWORD_MAX, UWORD_MIN, SWORD_MAX, SWORD_MIN via static_assert().
This commit is contained in:
parent
3d9e7ca4d4
commit
d3bd3ff48c
@ -52,7 +52,17 @@ int main(void)
|
||||
(ARCHITECTURE_WORD_BITS == CORRECT_WORD_BITS) &&
|
||||
(ARCHITECTURE_WORD_BYTES == CORRECT_WORD_BITS / 8) &&
|
||||
(sizeof(uword_t) == ARCHITECTURE_WORD_BYTES) &&
|
||||
(sizeof(sword_t) == ARCHITECTURE_WORD_BYTES),
|
||||
(sizeof(sword_t) == ARCHITECTURE_WORD_BYTES) &&
|
||||
(UWORD_MIN == 0) &&
|
||||
((ARCHITECTURE_WORD_BITS != 8) || (UWORD_MAX == 255)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 8) || (SWORD_MIN == -128)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 8) || (SWORD_MAX == 127)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 16) || (UWORD_MAX == 65535)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 16) || (SWORD_MIN == -32768)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 16) || (SWORD_MAX == 32767)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 32) || (UWORD_MAX == 4294967295)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 32) || (SWORD_MIN == -2147483648)) &&
|
||||
((ARCHITECTURE_WORD_BITS != 32) || (SWORD_MAX == 2147483647)),
|
||||
"word size details are incorrect"
|
||||
);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user