This is the mail archive of the
mailing list for the GCC project.
Re: Why does this not compile?
- From: Florian Weimer <fw at deneb dot enyo dot de>
- To: Matthijs van Duin <gcc at nubz dot org>
- Cc: gcc at gcc dot gnu dot org, vharron at soe dot sony dot com, aoliva at redhat dot com
- Date: Mon, 20 May 2002 00:14:42 +0200
- Subject: Re: Why does this not compile?
- References: <email@example.com><firstname.lastname@example.org>
Matthijs van Duin <email@example.com> writes:
> it's funny, when I see code of fellow students or even teachers, it
> seems that hardly anyone bothers to use const-qualifiers, or
> qualifiers in general
During my C++ days, I've repeatedly read rules of thumb like "const
creates constant confusion", referring to poisonous aspect of const
(once you add it somewhere, you have to add it in many places). Maybe
that feeling carries over to the pass-by-reference-to-constant-object
case, which is rather unwarranted, of course.