template/STL interaction

Alexandre Oliva oliva@dcc.unicamp.br
Mon Sep 28 17:39:00 GMT 1998


D Maley <d.maley@airforce1.stmarys-belfast.ac.uk> writes:

> Number One.

> bug.cpp: In method `Composite2<pair<int,float>
>> ::Composite2<pair<int,float>>()':
> bug.cpp:14:   instantiated from here
> bug.cpp:5: type `pair<pair<int,float>,T2>' is not a base type for type
> `Composite2<pair<int,float> >'

Fixed in the latest snapshot of egcs.

> Number Two.

> /usr/local/include/g++/stl_pair.h: In method
> `pair<Pair<int,float>,double>::pair<int, float>(const struct pair<int,float>
> &)':
> Composite.cpp:25:   instantiated from here
> /usr/local/include/g++/stl_pair.h:48: no matching function for call to
> `Pair<int,float>::Pair (const int &)'
> Composite.cpp:16: candidates are: Pair<int,float>::Pair(const Pair<int,float> &)
> Composite.cpp:23:                 Pair<int,float>::Pair<int, float>()
> Composite.cpp:25:                 Pair<int,float>::Pair<int, float>(int, float)

I can't reproduce this problem on sparc-sun-solaris2.5.  Perhaps
someone else with Solaris/x86 can.

>  I don't know what comprises a full bug report, so I've just given you the
> code and the messages. I'm on a P200 under Solaris 2.6.

http://egcs.cygnus.com/faq.html#bugreport

Next time, please send one bug report per message; it's much easier to 
deal with one bug report at a time.

Thanks for your report.

-- 
Alexandre Oliva
mailto:oliva@dcc.unicamp.br mailto:aoliva@acm.org
http://www.dcc.unicamp.br/~oliva
Universidade Estadual de Campinas, SP, Brasil




More information about the Gcc-bugs mailing list