gCAD3D 2.35
ut_cast.h File Reference

Go to the source code of this file.

Macros

#define LONG_PTR(vp1)   (long)vp1
 long from pointer long = LONG_PTR (ptr); More...
 
#define INT_PTR(vp1)   (int)((long)vp1)
 integer from pointer int = INT_PTR (ptr); More...
 
#define PTR_INT(i1)   (void*)((int)i1)
 pointer from integer ptr = PTR_INT (int); More...
 
#define PTR_LONG(l1)   (void*)l1
 pointer from long ptr = PTR_LONG (long); More...
 
#define PTR_CHRA(txt)   (void*)txt
 pointer from character-array ptr = PTR_CHRA (*txt); More...
 
#define TXT_PTR(vp1)   (char*)(vp1)
 text from pointer More...
 

Detailed Description

32-bit: sizeof(int) = 32 sizeof(long) = 32 sizeof(void*)= 32

64-bit: sizeof(int) = 32 sizeof(long) = 64 sizeof(void*)= 64

see also ../ut/ut_types.h

Macro Definition Documentation

#define LONG_PTR (   vp1)    (long)vp1

long from pointer long = LONG_PTR (ptr);

#define INT_PTR (   vp1)    (int)((long)vp1)

integer from pointer int = INT_PTR (ptr);

#define PTR_INT (   i1)    (void*)((int)i1)

pointer from integer ptr = PTR_INT (int);

#define PTR_LONG (   l1)    (void*)l1

pointer from long ptr = PTR_LONG (long);

#define PTR_CHRA (   txt)    (void*)txt

pointer from character-array ptr = PTR_CHRA (*txt);

#define TXT_PTR (   vp1)    (char*)(vp1)

text from pointer