logo       

RE: Problems with %rename (const): msg#00162

programming.swig

Subject: RE: Problems with %rename (const)

I'll have a look at a small example, but not a whole project. Try swig -E to
view the preprocessor output, that might show some light on the matter. The
position of the %template directive can sometimes have surprising effects.
Maybe you are looking at the wrong generated file? It has happened before :)

William

>-----Original Message-----
>From: swig-admin@xxxxxxxxxxxxxxx [mailto:swig-admin@xxxxxxxxxxxxxxx]On
>Behalf Of Emanuel Greisen
>Sent: 24 September 2004 12:52
>To: Swig@xxxxxxxxxxxxxxx
>Subject: RE: [Swig] Problems with %rename (const)
>
>
>I could also send you (or make available from http) my entire
>source-tree. There is a Makefile, doing all the things I do.
>
>On Fri, 2004-09-24 at 12:30, William.Fulton@xxxxxxx wrote:
>> Debugging SWIG is not for the faint hearted ;) , but the
>best way is to use swig -dump_tree to see the parse tree.
>
>I just took a look at the parsetree, and everything there seems
>perfectly "normal", there is exactly 2 methods, one getBoundingBox, and
>one getBoundingBoxConst. But in the generated javaCode, i have two
>getBoundingsBox-methods... thats what so weird.
>
>[snip:parsetree]
> +++ include ----------------------------------------
> | name - "./irrlicht-0.7/include/IMeshBuffer.h"
>
> +++ namespace
>----------------------------------------
> | sym:name - "irr"
> | name - "irr"
> | sym:previousSibling - 0x402442b8
> | csym:nextSibling - 0x40247098
> | sym:nextSibling - 0x40247098
> | typescope - 0x402a8bc8
> | symtab - 0x4009fdf8
> | feature:java:enum - "typesafe"
> | sym:symtab - 0x4001f198
>
> +++ namespace
>----------------------------------------
> | sym:name - "scene"
> | name - "scene"
> | csym:nextSibling - 0x402470f8
>....
>....
>....
> +++ cdecl
>----------------------------------------
> | value - "0"
> | proxyfuncname -
>"getBoundingBoxConst"
> | imfuncname -
>"IMeshBuffer_getBoundingBoxConst"
> | name - "getBoundingBox"
> | sym:symtab - 0x40246108
> | tmap:jtype - "long"
> | csym:nextSibling - 0x40246ca8
> | sym:name -
>"getBoundingBoxConst"
> | view -
>"memberfunctionHandler"
> | wrap:parms - 0x404dfd08
> | decl - "q(const).f().r."
> | tmap:jni - "jlong"
> | tmap:out - "
>*(irr::core::aabbox3d<irr::f32 > **)&jr..."
> | feature:java:enum - "typesafe"
> | tmap:javaout - "{\n return new
>aabbox3df(JirrJNI.IMes..."
> | abstract - "1"
> | wrap:action -
>"{\nirr::core::aabbox3d<irr::f32 > const ..."
> | type -
>"q(const).irr::core::aabbox3d<(irr::f32)>"
> | wrap:name -
>"Java_net_sf_jirr_JirrJNI_IMeshBuffer_1ge..."
> | qualifier - "q(const)."
> | sym:overname - "__SWIG_0"
> | storage - "virtual"
> | tmap:jstype - "aabbox3df"
> |
> +++ cdecl
>----------------------------------------
> | value - "0"
> | proxyfuncname - "getBoundingBox"
> | imfuncname -
>"IMeshBuffer_getBoundingBox"
> | name - "getBoundingBox"
> | sym:symtab - 0x40246108
> | tmap:jtype - "long"
> | sym:name - "getBoundingBox"
> | view -
>"memberfunctionHandler"
> | wrap:parms - 0x404e0718
> | decl - "f().r."
> | tmap:jni - "jlong"
> | tmap:out - "
>*(irr::core::aabbox3d<irr::f32 > **)&jr..."
> | feature:java:enum - "typesafe"
> | tmap:javaout - "{\n return new
>aabbox3df(JirrJNI.IMes..."
> | abstract - "1"
> | wrap:action -
>"{\nirr::core::aabbox3d<irr::f32 > &_resu..."
> | type -
>"irr::core::aabbox3d<(irr::f32)>"
> | wrap:name -
>"Java_net_sf_jirr_JirrJNI_IMeshBuffer_1ge..."
> | sym:overname - "__SWIG_0"
> | storage - "virtual"
> | tmap:jstype - "aabbox3df"
> |
> +++ clear ----------------------------------------
>
>
>[/snip:parsetree]
>
>_______________________________________________
>Swig maillist - Swig@xxxxxxxxxxxxxxx
>http://mailman.cs.uchicago.edu/mailman/listinfo/swig
>

Visit our website at http://www.ubs.com

This message contains confidential information and is intended only
for the individual named. If you are not the named addressee you
should not disseminate, distribute or copy this e-mail. Please
notify the sender immediately by e-mail if you have received this
e-mail by mistake and delete this e-mail from your system.

E-mail transmission cannot be guaranteed to be secure or error-free
as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses. The sender therefore
does not accept liability for any errors or omissions in the contents
of this message which arise as a result of e-mail transmission. If
verification is required please request a hard-copy version. This
message is provided for informational purposes and should not be
construed as a solicitation or offer to buy or sell any securities or
related financial instruments.

_______________________________________________
Swig maillist - Swig@xxxxxxxxxxxxxxx
http://mailman.cs.uchicago.edu/mailman/listinfo/swig



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise