Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
01/22/02 14:41
Read: times


 
#18973 - RE: typedef & optimisation?
A little trick I learned a while ago:

in one module only
#define MAIN

in the .h file

#ifdef MAIN
#define U8 unsigned char
...
...
#else
#define U8 extern unsigned char
...
...
#endif

U8 a_variable;

Now you have 'intern' and 'extern' defined the same place and no mistakes (in this regard :-) )are possible.

Have fun,

Erik

List of 21 messages in thread
TopicAuthorDate
typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation? Derek            01/01/70 00:00      
RE: typedef & optimisation? Peter            01/01/70 00:00      
RE: typedef & optimisation Franc            01/01/70 00:00      
RE: typedef & optimisation? Erik            01/01/70 00:00      
RE: typedef & optimisation? Peter            01/01/70 00:00      
RE: typedef & optimisation? Peter/Erik            01/01/70 00:00      
RE: typedef & optimisation? Peter/Erik            01/01/70 00:00      
RE: typedef & optimisation? Peter/Erik            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      
RE: typedef & optimisation?            01/01/70 00:00      

Back to Subject List