public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: c++/6088: templates calling static member functions won't compile
@ 2002-09-15 11:31 nathan
0 siblings, 0 replies; 4+ messages in thread
From: nathan @ 2002-09-15 11:31 UTC (permalink / raw)
To: claudius.link, gcc-bugs, gcc-prs, nobody
Synopsis: templates calling static member functions won't compile
State-Changed-From-To: open->analyzed
State-Changed-By: nathan
State-Changed-When: Sun Sep 15 11:31:31 2002
State-Changed-Why:
confirmed. I suspect it is because we don't instantiate
template members in declaration order.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=6088
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: c++/6088: templates calling static member functions won't compile
@ 2002-10-31 7:18 lerdsuwa
0 siblings, 0 replies; 4+ messages in thread
From: lerdsuwa @ 2002-10-31 7:18 UTC (permalink / raw)
To: claudius.link, gcc-bugs, gcc-prs, lerdsuwa
Synopsis: templates calling static member functions won't compile
State-Changed-From-To: analyzed->closed
State-Changed-By: lerdsuwa
State-Changed-When: Thu Oct 31 07:18:28 2002
State-Changed-Why:
Fixed in the main trunk.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=6088
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: c++/6088: templates calling static member functions won't compile
@ 2002-10-26 2:03 lerdsuwa
0 siblings, 0 replies; 4+ messages in thread
From: lerdsuwa @ 2002-10-26 2:03 UTC (permalink / raw)
To: claudius.link, gcc-bugs, gcc-prs, lerdsuwa, nobody
Synopsis: templates calling static member functions won't compile
Responsible-Changed-From-To: unassigned->lerdsuwa
Responsible-Changed-By: lerdsuwa
Responsible-Changed-When: Sat Oct 26 02:03:52 2002
Responsible-Changed-Why:
Patch in progress.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=6088
^ permalink raw reply [flat|nested] 4+ messages in thread
* c++/6088: templates calling static member functions won't compile
@ 2002-03-28 18:36 claudius.link
0 siblings, 0 replies; 4+ messages in thread
From: claudius.link @ 2002-03-28 18:36 UTC (permalink / raw)
To: gcc-gnats, debian-gcc
>Number: 6088
>Category: c++
>Synopsis: templates calling static member functions won't compile
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: unassigned
>State: open
>Class: rejects-legal
>Submitter-Id: net
>Arrival-Date: Thu Mar 28 18:36:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: Claudius Link
>Release: 3.0.3 (Debian testing/unstable)
>Organization:
IAM University Freiburg
>Environment:
System: Linux zaphod 2.4.18 #4 SMP Sun Mar 10 00:00:34 CET 2002 i686 unknown
Architecture: i686
host: i386-pc-linux-gnu
build: i386-pc-linux-gnu
target: i386-pc-linux-gnu
configured with: ../src/configure -v --enable-languages=c,c++,java,f77,proto,objc --prefix=/usr --infodir=/share/info --mandir=/share/man --enable-shared --with-gnu-as --with-gnu-ld --with-system-zlib --enable-long-long --enable-nls --without-included-gettext --disable-checking --enable-threads=posix --enable-java-gc=boehm --with-cpp-install-dir=bin --enable-objc-gc i386-linux
>Description:
When trying to compile the converion detection example from the article
Mappings between Types and Values
by
Andrei Alexandrescu
at
http://www.cuj.com/experts/1810/alexandr.htm?topic=experts
it simply didn't compile with the error message (2.95.2 and 2.95.4 neither):
------------------------------------------------
$ g++-3.0 -v -save-temps -o s s.cc
Reading specs from /usr/lib/gcc-lib/i386-linux/3.0.3/specs
Configured with: ../src/configure -v --enable-languages=c,c++,java,f77,proto,objc --prefix=/usr --infodir=/share/info --mandir=/share/man --enable-shared --with-gnu-as --with-gnu-ld --with-system-zlib --enable-long-long --enable-nls --without-included-gettext --disable-checking --enable-threads=posix --enable-java-gc=boehm --with-cpp-install-dir=bin --enable-objc-gc i386-linux
Thread model: posix
gcc version 3.0.3
/usr/lib/gcc-lib/i386-linux/3.0.3/cpp0 -lang-c++ -D__GNUG__=3 -D__GXX_DEPRECATED -D__EXCEPTIONS -D__GXX_ABI_VERSION=100 -v -D__GNUC__=3 -D__GNUC_MINOR__=0 -D__GNUC_PATCHLEVEL__=3 -D__ELF__ -Dunix -Dlinux -D__ELF__ -D__unix__ -D__linux__ -D__unix -D__linux -Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1 -D_GNU_SOURCE -Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i386__ s.cc s.ii
GNU CPP version 3.0.3 (cpplib) (i386 Linux/ELF)
ignoring nonexistent directory "/usr/i386-linux/include"
#include "..." search starts here:
#include <...> search starts here:
/usr/include/g++-v3
/usr/include/g++-v3/i386-linux
/usr/include/g++-v3/backward
/usr/local/include
/usr/lib/gcc-lib/i386-linux/3.0.3/include
/usr/include
End of search list.
/usr/lib/gcc-lib/i386-linux/3.0.3/cc1plus -fpreprocessed s.ii -quiet -dumpbase s.cc -version -o s.s
GNU CPP version 3.0.3 (cpplib) (i386 Linux/ELF)
GNU C++ version 3.0.3 (i386-linux)
compiled by GNU C version 3.0.3.
s.cc: In instantiation of `Conversion<double>':
s.cc:11: instantiated from here
s.cc:11: invalid use of undefined type `class Conversion<double>'
s.cc:3: forward declaration of `class Conversion<double>'
------------------------------------------------
The SGI 7.3 and the Sun C++ 5.1 work all right and I can't see any illigal
stuff done there.
I just include the source.
>How-To-Repeat:
# 1 "s.cc"
template <class T>
class Conversion
{
public:
static T MakeT();
enum { exists = sizeof(MakeT()) };
};
int main()
{
int i = Conversion<double>::exists;
}
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2002-10-31 15:18 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-15 11:31 c++/6088: templates calling static member functions won't compile nathan
-- strict thread matches above, loose matches on Subject: below --
2002-10-31 7:18 lerdsuwa
2002-10-26 2:03 lerdsuwa
2002-03-28 18:36 claudius.link
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).