🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Per Abrahamsen Tue, 29 Aug 1995 16:26
g++ 2.7.0: external definitions of local classes members of template classes?
#754
Author: Per Abrahamsen
Date: Tue, 29 Aug 1995 16:26
36 lines
1935 bytes
How does one do this?  Here is my attempt, which g++ 2.7.0 chockes on:

template <class T> class FTable
{
    struct Implementation;
};

template <class T>
struct FTable<T>::Implementation
{ };

cd ~/daisy/
make -k bug
c++ -Wall -fhandle-exceptions -pipe -g -v -c -o bug bug.C
 gcc -Wall -fhandle-exceptions -pipe -g -v -c -o bug bug.C
Reading specs from /pack/gcc/lib/gcc-lib/sparc-sun-solaris2.4/2.7.0/specs
gcc version 2.7.0
 /pack/gcc/lib/gcc-lib/sparc-sun-solaris2.4/2.7.0/cpp -lang-c++ -v -undef -D__GNUC__=2 -D__GNUG__=2 -D__cplusplus -D__GNUC_MINOR__=7 -Dsun -Dsparc -Dunix -D__svr4__ -D__SVR4 -D__GCC_NEW_VARARGS__ -D__sun__ -D__sparc__ -D__unix__ -D__svr4__ -D__SVR4 -D__GCC_NEW_VARARGS__ -D__sun -D__sparc -D__unix -Asystem(unix) -Asystem(svr4) -Acpu(sparc) -Amachine(sparc) -g -Wall bug.C |
 /pack/gcc/lib/gcc-lib/sparc-sun-solaris2.4/2.7.0/cc1plus -quiet -dumpbase bug.cc -g -Wall -version -fhandle-exceptions -o - |
 /usr/ccs/bin/as -V -Qy -s -o bug -
/usr/ccs/bin/as: SC3.1 dev 09 May 1994
GNU C++ version 2.7.0 (sparc) compiled by GNU C version 2.7.0.
GNU CPP version 2.7.0 (sparc)
#include "..." search starts here:
#include <...> search starts here:
 /pack/gcc/lib/g++-include
 /usr/local/include
 /pack/gcc/sparc-sun-solaris2.4/include
 /pack/gcc/lib/gcc-lib/sparc-sun-solaris2.4/2.7.0/include
 /usr/include
End of search list.
bug.C:8: parse error before `{'
make: *** [bug] Error 1

Compilation exited abnormally with code 1 at Tue Aug 29 17:36:09
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads