Re: C++ & Caml: name clash

From: John Max Skaller (skaller@maxtal.com.au)
Date: Wed Apr 19 2000 - 17:50:38 MET DST

  • Next message: John Max Skaller: "Re: When functional languages can be accepted by industry?"

    Ohad Rodeh wrote:
    >
    > Hello,
    > First of all, I'd like to thank all the replies for my
    > first question.
    >
    > My second problem has to do with a name clash between
    > the g++ standard library, and the alloc.h file from Caml.
    > It turns out that the function "alloc" is defined by g++
    > in file /usr/include/g++-2/stl_alloc.h as:
    > typedef class __default_alloc_template<true,0> alloc
    > In caml it is defined in include/alloc.h as:
    > value alloc(mlsize_t, tag_t)
    >
    > This does not allow compiling a file that #includes both
    > Caml and g++ header files.

    All parts of the C++ library reside in namespace 'std'.
    If there is a clash, it is a g++ bug.

    -- 
    John (Max) Skaller, mailto:skaller@maxtal.com.au
    10/1 Toxteth Rd Glebe NSW 2037 Australia voice: 61-2-9660-0850
    checkout Vyper http://Vyper.sourceforge.net
    download Interscript http://Interscript.sourceforge.net
    



    This archive was generated by hypermail 2b29 : Wed Apr 19 2000 - 20:59:59 MET DST