This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/11540] Redefinition of default arguments allowed for template functions
- From: "philippe dot haution at mines-paris dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 17 Jul 2003 08:38:49 -0000
- Subject: [Bug c++/11540] Redefinition of default arguments allowed for template functions
- References: <20030716081310.11540.philippe.haution@mines-paris.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11540
------- Additional Comments From philippe dot haution at mines-paris dot org 2003-07-17 08:38 -------
8.6.3/4 asserts that a default argument shall not be redefined by a later
declaration, not even to the same value; so I am afraid checking that all
declarations of default arguments have the same value wouldn't be enough here,
the compiler should also check that there is only one definition of default
arguments per translation unit.