Add a macro to define the size of a subsection of a structure.
Used in fork1() and thr_create()
This commit is contained in:
parent
4386366573
commit
622c9da995
@ -241,6 +241,8 @@
|
||||
* require it.
|
||||
*/
|
||||
#define __offsetof(type, field) ((size_t)(&((type *)0)->field))
|
||||
#define __rangeof(type, start, end) \
|
||||
(__offsetof(type, end) - __offsetof(type, start))
|
||||
|
||||
/*
|
||||
* Compiler-dependent macros to declare that functions take printf-like
|
||||
|
Loading…
x
Reference in New Issue
Block a user