This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: coding style, continuing education
- To: Mike Stump <mrs at windriver dot com>
- Subject: Re: coding style, continuing education
- From: Bruce Korb <bkorb at cruzio dot com>
- Date: Mon, 15 Jan 2001 14:53:15 -0800
- CC: gcc at gcc dot gnu dot org
- References: <200101152203.OAA29440@kankakee.wrs.com>
Mike Stump wrote:
> If people _know_ of a good way to split this down, maybe we all just
> need a refresher course on the right way, care to elaborate?
It's simple :-)
Put the `then' clause into a routine, recast the expression using
boolean algebra to reduce nesting and break it up into a series
of `if' statements that each have a clear purpose.
> if ( [[insufferable boolean expression elided]] )
> {