[GCC-XML] (__GLOBAL function was Problem exposing templates)

Balasubramanyam, Shivakumar sbalasub at qualcomm.com
Wed Aug 2 20:43:56 EDT 2006


>-----Original Message-----
>From: gccxml-bounces+sbalasub=qualcomm.com at gccxml.org [mailto:gccxml-
>bounces+sbalasub=qualcomm.com at gccxml.org] On Behalf Of Roman Yakovenko
>Sent: Tuesday, August 01, 2006 10:02 PM
>To: Development of Python/C++ integration
>Cc: gccxml at gccxml.org
>Subject: [GCC-XML] Re: [C++-sig] Problem exposing templates
>
>On 8/2/06, Balasubramanyam, Shivakumar <sbalasub at qualcomm.com> wrote:
>> Hi,
>
>Good morning.
>
>> Is there any ways else to explicitly instantiate the template?
>
>Yes, you can write C++ code that uses that functions and feed it to
gccxml.
>
>P.S. Also gccxml is involved in the process it has nothing to do with
>the problem:
>http://gccxml.org/HTML/FAQ.html

[shiva] Roman, I understood the second part of my question, which was
using typedef for explicit instantiation.

Now I declared using "typedef Stack<int>::Stack Stack_Int;"

I still see pyplusplus generate the _GLOBAL function (see below) which
results in compilation error? 

    { //::_GLOBAL__D_Stack.hLZJ4nd
    
        typedef void ( *function_ptr_t )(  );
        
        bp::def( 
            "_GLOBAL__D_Stack.hLZJ4nd"
            , function_ptr_t( &::_GLOBAL__D_Stack.hLZJ4nd )
            , bp::default_call_policies() );
    
    }

    { //::_GLOBAL__I_Stack.hLZJ4nd
    
        typedef void ( *function_ptr_t )(  );
        
        bp::def( 
            "_GLOBAL__I_Stack.hLZJ4nd"
            , function_ptr_t( &::_GLOBAL__I_Stack.hLZJ4nd )
            , bp::default_call_policies() );
    
    }

Thanks,
Shiva






More information about the gccxml mailing list