> On 17 Oct 2013, at 17:47, berenger.mo...@neutralite.org wrote:
> 
> I do not understand why?
> In both cases with "decent compilers" it is solved at compile-time, so what 
> is the problem with preprocessor here? In case BIG_ENDIAN is not defined but 
> should be?

For the reason I wrote:

> otherwise you run the risk of never
> testing code outside the branch your dev machine(s) match.

Imagine you compile and test your code on a big endian machine 99% of the time. 
Imagine you make a mistake in the little-endian branch. With the cpp approach, 
the compiler won't see the buggy code. With the other approach, it will, and 
may catch the mistake.

Reply via email to