This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Silly brackets (Was: Re: Problems extending Python with C.)
- To: sk at nvg dot unit dot no (Steinar Knutsen)
- Subject: Re: Silly brackets (Was: Re: Problems extending Python with C.)
- From: François Pinard <pinard at iro dot umontreal dot ca>
- Date: 19 Feb 2000 23:24:34 -0500
- Cc: python-list at python dot org, bug-gcc at gnu dot org
- References: <Pine.NEB.4.05.10002192231120.6393-100000@nepe.nvg.ntnu.no> <88ne3e$hcs$1@snipp.uninett.no>
sk@nvg.unit.no (Steinar Knutsen) writes:
> The problem described below was caused by my misplacing a bracket in
> the C-part of the code. As my Python-trained brain only looked at the
> indentation, the error was easily missed. Remind me to flame the next
> guy who claims indentation is brittle and brackets are robust. :)
I believed, for years, that C compilers should have an option to emit
warning diagnostics when indentation is not consistent with brackets.
It is a big waste, in my opinion, that compilers ignore all that redundancy,
while it could be used to better help programmers.
P.S. - Copy sent to bug-gcc, in hope someone in there will agree :-).
I tried to convince Richard a few times in the past years, and suggested
various heuristics, but I probably did not succeed at raising his interest.
--
François Pinard http://www.iro.umontreal.ca/~pinard