w_base.h File Reference


Detailed Description

Basic types.

Definition in file w_base.h.

Go to the source code of this file.

Classes

class  w_base_t
 The mother base class for most types. More...
class  w_vbase_t
 Class that adds virtual destructor to w_base_t. More...
struct  fill1
 Auto-initialized 1-byte filler for alignment of structures. More...
struct  fill2
 Auto-initialized 2-byte filler for alignment of structures. More...
struct  fill3
 Auto-initialized 3-byte filler for alignment of structures. More...
struct  fill4
 Auto-initialized 4-byte filler for alignment of structures. More...
struct  CompileTimeAssertion< true >
 Compile-time assertion trick. More...
struct  compile_time_assert< T >
 Compile-time assertion trick. More...

Defines

#define W_UNIX
#define NORET
#define CAST(t, o)   ((t)(o))
#define W_UNUSED(x)
#define W_IFDEBUG1(x)
#define W_IFNDEBUG1(x)   x
#define W_IFDEBUG2(x)
#define W_IFNDEBUG2(x)   x
#define W_IFDEBUG3(x)
#define W_IFNDEBUG3(x)   x
#define W_IFDEBUG4(x)
#define W_IFNDEBUG4(x)   x
#define W_IFDEBUG9(x)
#define W_IFNDEBUG9(x)   x
#define W_IFDEBUG(x)
#define W_IFNDEBUG(x)   x
#define W_IFTRACE(x)
#define W_IFNTRACE(x)   x
#define W_SPACE
#define w_assert0(x)
 Default assert/debug level is 0.
#define W_DEBUG_LEVEL   0
#define w_assert1(x)
 Level 1 should not add significant extra time.
#define w_assert2(x)
 Level 2 adds some time.
#define w_assert3(x)
 Level 3 definitely adds significant time.
#define w_assert4(x)
 Level 4 can be a hog.
#define w_assert5(x)
 Level 5 is not yet used.
#define w_assert9(x)
 changing an assert to an assert9 turns it off.
#define W_ENUM(x)   ((int)(x))
 Cast to treat an enum as integer value.
#define W_ADDR(x)   ((void *)(x))
 Cast to treat a pointer as a non-(char *) value.
#define alignonarg(a)   (((ptrdiff_t)(a))-1)
 helper for alignon
#define alignon(p, a)   (((ptrdiff_t)((ptrdiff_t)(p) + alignonarg(a))) & ~alignonarg(a))
 aligns a pointer p on a size a
#define ALIGNON   0x8
#define ALIGNON1   (ALIGNON-1)
#define align(sz)   ((size_t)((sz + ALIGNON1) & ~ALIGNON1))
#define w_reset_strstream(s)
 Allow a ostrstream to be reused.
#define ASSERT_FITS_IN_POINTER(T)
#define ASSERT_FITS_IN_LONGLONG(T)


Define Documentation

#define W_ENUM (  )     ((int)(x))

Cast to treat an enum as integer value.

This is used when a operator<< doesn't exist for the enum. The use of the macro indicates that this enum would be printed if it had a printer, rather than wanting the integer value of the enum

Definition at line 245 of file w_base.h.

#define W_ADDR (  )     ((void *)(x))

Cast to treat a pointer as a non-(char *) value.

This is used when a operator<< is used on a pointer. Without this cast, some values would bind to 'char *' and attempt to print a string, rather than printing the desired pointer value.

Definition at line 254 of file w_base.h.


Generated on Wed Jul 7 17:22:32 2010 for Shore Storage Manager by  doxygen 1.4.7