function pointers
Status: Alpha
Brought to you by:
skieble
The return type of "get" method of "std::map" is not translated correctly.
The error information is following.
[javac] /home/jieshen/work/xbig/trunk/tests/Ogre3D/build/java/org/xbig/Ogre/CompositorScriptCompiler.java:101: <identifier> expected
[javac] public void(CompositorScriptCompiler::*) get(Integer key) {
[javac] ^
[javac] /home/jieshen/work/xbig/trunk/tests/Ogre3D/build/java/org/xbig/Ogre/CompositorScriptCompiler.java:101: <identifier> expected
[javac] public void(CompositorScriptCompiler::*) get(Integer key) {
Logged In: YES
user_id=1568577
Originator: NO
See t13_? for std::map. In many cases it is correct. Please provide the typedef for which this error occurs.
Logged In: YES
user_id=1385755
Originator: YES
The typedef as follows:x
typedef std::map<size_t, CSC_Action> TokenActionMap;
Logged In: YES
user_id=1568577
Originator: NO
CSC_Action is defined as follows:
typedef void(CompositorScriptCompiler::* Ogre::CompositorScriptCompiler::CSC_Action)
CompositorScriptCompiler::* is not handled, so it is used in Java.
I think we should put Ogre::CompositorScriptCompiler::TokenActionMap on ignore_list.
Logged In: YES
user_id=1385755
Originator: YES
>CompositorScriptCompiler::* is not handled, so it is used in Java.
I don't quite understand what you mean.
CSC_Action is defined as follow:
typedef void (CompositorScriptCompiler::* CSC_Action)(void);
So i think it's a function pointer.
Logged In: YES
user_id=1568577
Originator: NO
Oh yes, it is a function pointer, I didn't realize this. Function pointers are not handled. So "CompositorScriptCompiler::*" is used as type in meta. This type cannot be resolved and thus it is just copied to Java Code. I think we should ignore std::maps which contain function pointers. Anyway, how should be map a function pointer to Java?
Logged In: YES
user_id=1385755
Originator: YES
yes, i also think we can ignore it before we finish other features needed by OGRE.