Topic: Problems compiling with STL and Sun CC 4.0.1


Author: jak@cs.brown.edu (Jak Kirman)
Date: 29 Mar 1995 04:50:46 GMT
Raw View
I ftp'ed, from HP, a version of the STL dated 7 Feb 95, and I am using
Sun's C++ compiler: CC-4.0.1: SC3.0.1 13 Jul 1994.

The compiler barfs here:

    template <class T>
    class vector {
    ...
        typedef vector_allocator::pointer pointer;
    ...
    };

    "./vector.h", line 38: Error: "," expected instead of "pointer".


Commenting this and similar declarations out gets rid of this problem,
but then the compiler complains about multiple declarations of
insert_aux and other vector functions that are defined outside the
class.

Has anyone successfully used STL with Sun's compiler?  If so, do you
have any advice?  If not, does anyone else have any advice?  :-)

Thanks.
                         Jak Kirman                        jak@cs.brown.edu
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Vi is a piece of wombat do.
                            -- Title of 1985 European UNIX User Group debate