I don't know if it's too late, but there is yet another reason
for the use of generalized lvalues besides just ignorance:
using them in macros that verify pointer and struct usage
in a large framework. A comma expression makes it very
convenient, for example (just a general idea):
#ifdef PRODUCT
Florian Weimer wrote:
* Michael Krasnik:
#ifdef PRODUCTION
#define X_ABC(x) ( check( x ), x->abc )
#else
#define X_ABC(x)x->abc
#endif
which expands
X_ABC(x) = y;
to:
( check( x ), x->abc ) = y;
Eliminating this construct makes macros much less fle
Andrew Pinski wrote:
I don't know if it's too late, but there is yet another reason
for the use of generalized lvalues besides just ignorance:
using them in macros that verify pointer and struct usage
in a large framework. A comma expression makes it very
convenient, for example (just a general i