- object in heap for large (i.e. size in bytes more than
- WX_ANY_VALUE_BUFFER_SIZE) or non-POD (Plain Old Data) data types.
- Pointers, integers, bools etc. are fitted in the wxAny's internal buffer
- without need for any extra allocation. It is possible that wxAny cannot
- automatically determine if your own data structure is considered a
- POD or not, so you may need to declare it as such explicitly, using
- code like this:
-
- @code
- #include "wx/meta/pod.h"
- WX_DECLARE_TYPE_POD(MyPodStruct)
- @endcode
-
- Be extra careful what you declare as Plain Old Data. It must be such data
- that can be copied with memcpy() without corrupting program integrity. For
- instance, POD structures usually cannot contain pointers or references to
- other data. wxRect, wxPoint, and wxSize are good examples of POD
- classes.
-
- Note that pointers to any and all types are already automatically
- declared as Plain Old Data.
+ object in heap for large objects (i.e. ones with size more than
+ WX_ANY_VALUE_BUFFER_SIZE, which at the time of writing is 16 bytes).