Home | History | Annotate | Download | only in base

Lines Matching defs:arraysize

13 // The arraysize(arr) macro returns the # of elements in an array arr.
15 // used in defining new arrays, for example. If you use arraysize on
18 // One caveat is that arraysize() doesn't accept any array of an
20 // cases, you have to use the unsafe ARRAYSIZE() macro below. This is
24 // This template function declaration is used in defining arraysize.
38 #define arraysize(array) (sizeof(ArraySizeHelper(array)))
40 // ARRAYSIZE performs essentially the same calculation as arraysize,
42 // functions. It's less safe than arraysize as it accepts some
43 // (although not all) pointers. Therefore, you should use arraysize
46 // The expression ARRAYSIZE(a) is a compile-time constant of type
49 // ARRAYSIZE catches a few type errors. If you see a compiler error
53 // when using ARRAYSIZE, you are (wrongfully) giving it a pointer.
54 // You should only use ARRAYSIZE on statically allocated arrays.
59 // ARRAYSIZE(arr) works by inspecting sizeof(arr) (the # of bytes in
77 // Starting with Visual C++ 2005, WinNT.h includes ARRAYSIZE.