public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c++/10505: g++ 3.2.1 on sun won't compile obj with list ofobj as member data
@ 2003-04-25 17:56 tjj
  0 siblings, 0 replies; only message in thread
From: tjj @ 2003-04-25 17:56 UTC (permalink / raw)
  To: gcc-gnats


>Number:         10505
>Category:       c++
>Synopsis:       g++ 3.2.1 on sun won't compile obj with list ofobj as member data
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          rejects-legal
>Submitter-Id:   net
>Arrival-Date:   Fri Apr 25 17:56:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     tjj@aol.net
>Release:        g++ 3.2.1
>Organization:
>Environment:
SunOS foobar 5.7 Generic_106541-11 sun4u sparc SUNW,Ultra-5_10
>Description:

>How-To-Repeat:
Put following into foo.cc
include <list>

class   Foo
{
public:
    int             x;
    std::list<Foo>  children;
};

then

g++ -c foo.cc

(note: Works fine on Linux x86)
>Fix:
Change std::list<Foo> children to std::list<Foo> *children
and fix code that references it. ugh 
>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: text/plain; name="foo-error.txt"
Content-Disposition: inline; filename="foo-error.txt"


foobar%	cat foo.cc
#include <list>

class   Foo
{
public:
    int             x;
    std::list<Foo>  children;
};
foobar%	g++ -c  -save-temps foo.cc
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/boost_concept_check.h: In instantiation of `__gnu_cxx::_SGIAssignableConcept<Foo>':
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/stl_list.h:293:   instantiated from `std::list<Foo, std::allocator<Foo> >'
foo.cc:7:   instantiated from here
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/boost_concept_check.h:182: `
   __gnu_cxx::_SGIAssignableConcept<_Tp>::__a' has incomplete type
foo.cc:4: forward declaration of `class Foo'
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/boost_concept_check.h: In 
   member function `void __gnu_cxx::_SGIAssignableConcept<_Tp>::__constraints() 
   [with _Tp = Foo]':
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/stl_list.h:293:   instantiated from `std::list<Foo, std::allocator<Foo> >'
foo.cc:7:   instantiated from here
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/boost_concept_check.h:174: `
   struct __gnu_cxx::_SGIAssignableConcept<Foo>' has no member named `__a'
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/stl_list.h:293:   instantiated from `std::list<Foo, std::allocator<Foo> >'
foo.cc:7:   instantiated from here
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/boost_concept_check.h:175: `
   struct __gnu_cxx::_SGIAssignableConcept<Foo>' has no member named `__a'
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/boost_concept_check.h:175: `
   struct __gnu_cxx::_SGIAssignableConcept<Foo>' has no member named `__a'
/cm/tools/paks/gcc-3.2.1/include/c++/3.2.1/bits/boost_concept_check.h:176: `
   struct __gnu_cxx::_SGIAssignableConcept<Foo>' has no member named `__a'
foobar%	


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-04-25 17:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-04-25 17:56 c++/10505: g++ 3.2.1 on sun won't compile obj with list ofobj as member data tjj

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).