This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: Optimzed vs. readable code
- From: Gabriel Dos Reis <gdr at integrable-solutions dot net>
- To: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- Cc: caj at cs dot york dot ac dot uk, Pierre THIERRY <nowhere dot man at levallois dot eu dot org>, libstdc++ at gcc dot gnu dot org
- Date: 01 Dec 2005 11:59:56 +0100
- Subject: Re: Optimzed vs. readable code
- References: <pan.2005.11.29.16.48.37.733665@levallois.eu.org> <F2B5F487-EF4D-43E4-B2D2-AD7EA914F24F@apple.com> <pan.2005.11.29.22.27.59.180878@levallois.eu.org> <4348dea50511300918w1a9a9ad1g@mail.gmail.com> <20051130173343.GD18129@bateleur.arcanes.fr.eu.org> <58115.83.70.108.191.1133375262.squirrel@www.cs.york.ac.uk> <4348dea50512010110m5a36b5ak@mail.gmail.com>
Jonathan Wakely <jwakely.gcc@gmail.com> writes:
| On 11/30/05, caj@cs.york.ac.uk <caj@cs.york.ac.uk> wrote:
| > that you may as well just add a comment saying "We use the first iterator
| > to keep the current position".
|
| Now that's a good idea.
I think comments should say why we're doing what we're doing, not repeat
what I'm reading.
My advice is get used to it, just as you'd get used to
if (Call* call = dynamic_cast<Call*>(expr))
...
-- Gaby