fix of small typo

Horst von Brand vonbrand@inf.utfsm.cl
Fri Dec 4 05:24:00 GMT 1998


Jeffrey A Law <law@hurl.cygnus.com> said:
>   In message < 199812032058.RAA21785@pincoya.inf.utfsm.cl >you write:
>   > mrs@wrs.com (Mike Stump) said:

>   > [...]

>   > >   #define ASM_FILE_START(FILE) \
>   > > !   do {	output_file_directive (FILE, main_input_filename);	\
>   > >     } while (0)

>   > Can't the do{ .. }while(0) be removed here?
> I don't recommend removing them.

> The do { ... } while (0) constructs make maintenance significantly easier.
> 
> Such constructs are much more tolerant of being used in if/else arms
> safely for example.

That is certainly true, but it is (or should be?) superfluous in this
particular case. I for one prefer to have to simplest, cleanest code
possible at all times. If not, somebody _will_ start wondering someday what
is missing inside the do { ... } while(0).

Just different styles to program, I guess. Not even a small deal ;-)
-- 
Dr. Horst H. von Brand                       mailto:vonbrand@inf.utfsm.cl
Departamento de Informatica                     Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria              +56 32 654239
Casilla 110-V, Valparaiso, Chile                Fax:  +56 32 797513




More information about the Gcc-patches mailing list