diff options
author | Mattias Andrée <maandree@operamail.com> | 2015-10-16 06:50:41 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2015-10-16 06:50:41 +0200 |
commit | a3d7a8fe7185cb568b2832b858c2f5b69e63789c (patch) | |
tree | 9adb1a7b0f0a45233f1cac0283503513a4be5b95 | |
parent | m info (diff) | |
download | slibc-a3d7a8fe7185cb568b2832b858c2f5b69e63789c.tar.gz slibc-a3d7a8fe7185cb568b2832b858c2f5b69e63789c.tar.bz2 slibc-a3d7a8fe7185cb568b2832b858c2f5b69e63789c.tar.xz |
m offsetof doc
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r-- | include/stddef.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/stddef.h b/include/stddef.h index 696af02..e33cfed 100644 --- a/include/stddef.h +++ b/include/stddef.h @@ -72,7 +72,10 @@ #define offsetof(type, member) \ ((size_t)((char*)&(((type*)NULL)->member) - (char*)NULL)) /* TODO The behaviour of this is undefined, and a builtin function - * shall be used when available. That would also improve diagnostics. */ + * shall be used when available. That would also improve diagnostics. + * If compilers that support ({ }), NULL could be replaced with a + * temporary variable, this would only remove the undefined behaviour, + * but any serious compiler should support the current implementation. */ |