stdcxx-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Sebor <se...@roguewave.com>
Subject Re: Incomplete types - compilation problem
Date Mon, 20 Feb 2006 21:18:58 GMT
I created STDCXX-152 to keep track of this enhancement:
   http://issues.apache.org/jira/browse/STDCXX-152

Martin

Martin Sebor wrote:
> Dipak Bapatla wrote:
> 
>> Hi,
>>      I am trying to use Boost built using stdcxx on Solaris. I was 
>> able to
>> build the date_time library but when I try to compile a test program I
>> end up with errors related to incomplete types. I have narrowed the
>> issue to the following code
>>      #include <map>
>> #include <string>
>>   using namespace std;
>>   template <class T>
>> struct C {
>>      typedef multimap<T,C> maps;
>>      typedef typename maps::value_type value_type;
> 
> 
> All containers require that their element types be complete types.
> Except in the bodies of its member functions (and a few other cases)
> a class is considered a complete type after the closing curly bracket.
> So the above is undefined.
> 
> We have an enhancement request in our (Rogue Wave) database to allow
> incomplete types in some of our containers (in particular in map) but
> the enhancement is not implemented yet. Let me add your case to the
> issue.
> 
> Martin


Mime
View raw message