public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation
@ 2004-02-25 1:49 s_gccbugzilla at nedprod dot com
2004-02-25 1:50 ` [Bug c++/14284] " s_gccbugzilla at nedprod dot com
` (7 more replies)
0 siblings, 8 replies; 9+ messages in thread
From: s_gccbugzilla at nedprod dot com @ 2004-02-25 1:49 UTC (permalink / raw)
To: gcc-bugs
GCC v3.4 CVS 20040218: Obviously the zero based specialisation should be chosen
here, not an ambiguous choice error. It even says so itself:
g++ -fPIC -Wformat -Wno-reorder -Wno-non-virtual-dtor -march=i486
-mcpu=athlon-xp -fexceptions -fkeep-inline-functions -g -DFOXDLL -DUSE_POSIX
-DHAVE_CONSTTEMPORARIES -D_DEBUG -DHAVE_XSHM_H -DHAVE_XCURSOR_H=1 -DHAVE_XFT_H=1
-DXTHREADS=1 -DFOX_THREAD_SAFE=1 -DHAVE_LIBDL=1 -DHAVE_CUPS_H=1 -DSTDC_HEADERS=1
-DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1
-DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1
-DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_SYS_WAIT_H=1
-DHAVE_DIRENT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_PARAM_H=1 -DHAVE_SYS_SELECT_H=1
-DBUILDING_TCOMMON -DFOXDLL_EXPORTS -DHAVE_JPEG_H -DHAVE_PNG_H -DHAVE_TIFF_H
-DHAVE_ZLIB_H -DHAVE_OPENSSL -DHAVE_GL_H -DSUN_OGL_NO_VERTEX_MACROS
-DHPOGL_SUPPRESS_FAST_API -DHAVE_GLU_H -ITnFOX/include -I/usr/kerberos/include
-I/usr/X11R6/include -I/usr/include/freetype2 -Iinclude -c -o
objs/Debug/THelpString.os src/THelpString.cxx
`-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead.
TnFOX/include/FXGenericTools.h: In constructor `FX::Generic::Bind::Impl<pars,
fn>::Impl(P1) [with P1 = FX::FXString*, int pars = 1, fn = void (*)(FX::
FXString*)]':
TnFOX/include/FXGenericTools.h:1582: instantiated from `FX::Generic::
BoundFunctor<typename FX::Generic::FnInfo<fn>::asList>* FX::Generic::
BindFuncN(fn, P1) [with fn = void (*)(FX::FXString*), P1 = FX::FXString*]'
src/THelpString.cxx:85: instantiated from here
TnFOX/include/FXGenericTools.h:1542: error: ambiguous class template
instantiation for `struct FX::Generic::TL::InstantiateHelperH::findType<FX::
Generic::TL::instantiateH<FX::Generic::TL::item<FX::FXString*, FX::Generic::
NullType>, FX::Generic::TL::instanceHolderH>, 0>'
TnFOX/include/FXGenericTools.h:698: error: candidates are: struct FX::Generic::
TL::InstantiateHelperH::findType<FX::Generic::TL::instantiateH<typelist,
instance>, i>
TnFOX/include/FXGenericTools.h:693: error: struct FX::Generic::
TL::InstantiateHelperH::findType<FX::Generic::TL::instantiateH<typelist,
instance>, 0>
TnFOX/include/FXGenericTools.h:1542: error: no matching function for call to
`instance(FX::Generic::TL::instantiateH<FX::Generic::TL::item<FX::FXString*, FX:
:Generic::NullType>, FX::Generic::TL::instanceHolderH>&)'
scons: *** [objs/Debug/THelpString.os] Error 1
Cheers,
Niall
--
Summary: v3.4 regression: Failure to select obvious template
specialisation
Product: gcc
Version: 3.4.0
Status: UNCONFIRMED
Severity: critical
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: s_gccbugzilla at nedprod dot com
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] v3.4 regression: Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
@ 2004-02-25 1:50 ` s_gccbugzilla at nedprod dot com
2004-02-25 16:46 ` bangerth at dealii dot org
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: s_gccbugzilla at nedprod dot com @ 2004-02-25 1:50 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From s_gccbugzilla at nedprod dot com 2004-02-25 01:50 -------
Created an attachment (id=5794)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=5794&action=view)
Preprocessor output causing bug
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] v3.4 regression: Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
2004-02-25 1:50 ` [Bug c++/14284] " s_gccbugzilla at nedprod dot com
@ 2004-02-25 16:46 ` bangerth at dealii dot org
2004-02-25 17:33 ` [Bug c++/14284] [3.4/3.5 regression] " bangerth at dealii dot org
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: bangerth at dealii dot org @ 2004-02-25 16:46 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bangerth at dealii dot org 2004-02-25 16:46 -------
I'm reducing this right now.
W.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] [3.4/3.5 regression] Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
2004-02-25 1:50 ` [Bug c++/14284] " s_gccbugzilla at nedprod dot com
2004-02-25 16:46 ` bangerth at dealii dot org
@ 2004-02-25 17:33 ` bangerth at dealii dot org
2004-02-26 14:02 ` giovannibajo at libero dot it
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: bangerth at dealii dot org @ 2004-02-25 17:33 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bangerth at dealii dot org 2004-02-25 17:33 -------
OK, this was a little tougher than thought, but it's clear:
---------------------
template<typename> struct S;
template<typename, template<class> class> struct I {};
template<class, int> struct Match;
template<typename T, template<class> class C>
struct Match<I<T,C>, 0> {};
template<typename T, template<class> class C, int i>
struct Match<I<T,C>, i> {};
Match<I<int,S>, 0> v;
----------------------
This should certainly compile:
g/x> /home/bangerth/bin/gcc-3.3.4-pre/bin/c++ -c x.cc
g/x> /home/bangerth/bin/gcc-3.4-pre/bin/c++ -c x.cc
x.cc:12: error: ambiguous class template instantiation for `struct
Match<I<int, S>, 0>'
x.cc:10: error: candidates are: struct Match<I<T, C>, i>
x.cc:7: error: struct Match<I<T, C>, 0>
x.cc:12: error: aggregate `Match<I<int, S>, 0> v' has incomplete type and
cannot be defined
x.cc:12: error: storage size of `v' isn't known
g/x> /home/bangerth/bin/gcc-3.5-pre/bin/c++ -c x.cc
x.cc:12: error: ambiguous class template instantiation for `struct
Match<I<int, S>, 0>'
x.cc:10: error: candidates are: struct Match<I<T, C>, i>
x.cc:7: error: struct Match<I<T, C>, 0>
x.cc:12: error: aggregate `Match<I<int, S>, 0> v' has incomplete type and
cannot be defined
x.cc:12: error: storage size of `v' isn't known
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Keywords| |rejects-valid
Known to fail| |3.4.0 3.5.0
Known to work| |3.3.4
Priority|P3 |P2
Last reconfirmed|0000-00-00 00:00:00 |2004-02-25 17:33:28
date| |
Summary|v3.4 regression: Failure to |[3.4/3.5 regression] Failure
|select obvious template |to select obvious template
|specialisation |specialisation
Target Milestone|--- |3.4.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] [3.4/3.5 regression] Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
` (2 preceding siblings ...)
2004-02-25 17:33 ` [Bug c++/14284] [3.4/3.5 regression] " bangerth at dealii dot org
@ 2004-02-26 14:02 ` giovannibajo at libero dot it
2004-02-26 17:39 ` giovannibajo at libero dot it
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: giovannibajo at libero dot it @ 2004-02-26 14:02 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From giovannibajo at libero dot it 2004-02-26 14:02 -------
Mine.
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |giovannibajo at libero dot
|dot org |it
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] [3.4/3.5 regression] Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
` (3 preceding siblings ...)
2004-02-26 14:02 ` giovannibajo at libero dot it
@ 2004-02-26 17:39 ` giovannibajo at libero dot it
2004-02-26 20:46 ` cvs-commit at gcc dot gnu dot org
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: giovannibajo at libero dot it @ 2004-02-26 17:39 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From giovannibajo at libero dot it 2004-02-26 17:39 -------
Patch posted:
http://gcc.gnu.org/ml/gcc-patches/2004-02/msg02499.html
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] [3.4/3.5 regression] Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
` (4 preceding siblings ...)
2004-02-26 17:39 ` giovannibajo at libero dot it
@ 2004-02-26 20:46 ` cvs-commit at gcc dot gnu dot org
2004-02-27 1:40 ` giovannibajo at libero dot it
2004-02-27 1:40 ` cvs-commit at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-02-26 20:46 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-02-26 20:46 -------
Subject: Bug 14284
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: giovannibajo@gcc.gnu.org 2004-02-26 20:46:09
Modified files:
gcc/cp : ChangeLog pt.c
gcc/testsuite : ChangeLog
Added files:
gcc/testsuite/g++.dg/template: ttp8.C
Log message:
PR c++/14284
* pt.c (dependent_type_p_r): A template template parameter is a
dependent type.
PR c++/14284
* g++.dg/template/ttp8.C: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&r1=1.3971&r2=1.3972
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/pt.c.diff?cvsroot=gcc&r1=1.831&r2=1.832
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.3544&r2=1.3545
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/ttp8.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] [3.4/3.5 regression] Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
` (5 preceding siblings ...)
2004-02-26 20:46 ` cvs-commit at gcc dot gnu dot org
@ 2004-02-27 1:40 ` giovannibajo at libero dot it
2004-02-27 1:40 ` cvs-commit at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: giovannibajo at libero dot it @ 2004-02-27 1:40 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From giovannibajo at libero dot it 2004-02-27 01:40 -------
Fixed in GCC 3.4.0 and GCC 3.5.0. Thanks for your report!
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/14284] [3.4/3.5 regression] Failure to select obvious template specialisation
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
` (6 preceding siblings ...)
2004-02-27 1:40 ` giovannibajo at libero dot it
@ 2004-02-27 1:40 ` cvs-commit at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-02-27 1:40 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-02-27 01:39 -------
Subject: Bug 14284
CVSROOT: /cvs/gcc
Module name: gcc
Branch: gcc-3_4-branch
Changes by: giovannibajo@gcc.gnu.org 2004-02-27 01:39:55
Modified files:
gcc/cp : ChangeLog pt.c
gcc/testsuite : ChangeLog
Added files:
gcc/testsuite/g++.dg/template: ttp8.C
Log message:
PR c++/14284
* pt.c (dependent_type_p_r): A template template parameter is a
dependent type.
PR c++/14284
* g++.dg/template/ttp8.C: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.3892.2.61&r2=1.3892.2.62
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/pt.c.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.816.2.12&r2=1.816.2.13
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.3389.2.111&r2=1.3389.2.112
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/ttp8.C.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=NONE&r2=1.1.2.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14284
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2004-02-27 1:40 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-02-25 1:49 [Bug c++/14284] New: v3.4 regression: Failure to select obvious template specialisation s_gccbugzilla at nedprod dot com
2004-02-25 1:50 ` [Bug c++/14284] " s_gccbugzilla at nedprod dot com
2004-02-25 16:46 ` bangerth at dealii dot org
2004-02-25 17:33 ` [Bug c++/14284] [3.4/3.5 regression] " bangerth at dealii dot org
2004-02-26 14:02 ` giovannibajo at libero dot it
2004-02-26 17:39 ` giovannibajo at libero dot it
2004-02-26 20:46 ` cvs-commit at gcc dot gnu dot org
2004-02-27 1:40 ` giovannibajo at libero dot it
2004-02-27 1:40 ` cvs-commit at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).