Is it possible to replace macros with constants, if macro is defined with another macro like this:
#define START_OFFSET 0
#define ADDRESS_OFFSET (START + START_SIZE)
#define SIZE_OFFSET (ADDRESS_OFFSET + ADDRESS_SIZE)
and so on
I'm not entirely sure, what will happen if I use global constants and initialize them with constants. Can that be considered safe?
The reason for using constants is for the possibility to wrap them into namespace. Btw, I'm using macros like these only for working with messages which are stored in byte arrays.
Is structure serialization is better option?