summaryrefslogtreecommitdiffstats
path: root/src/java/com/jogamp/gluegen/JavaEmitter.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2015-03-06 07:41:58 +0100
committerSven Gothel <[email protected]>2015-03-06 07:41:58 +0100
commit1df503b8f14b385b35c6b50a4ff7ff03d1c3134f (patch)
treec72874810009800c93bf83b46a8057f43d5392f2 /src/java/com/jogamp/gluegen/JavaEmitter.java
parent4183867b055e99762d9b1a9163012657738be31a (diff)
Bug 1134 - Fix ProcAddressEmitter.getFunctionPointerTypedefName() ; Fix JavaEmitter's Function/Struct Emission
Fix ProcAddressEmitter.getFunctionPointerTypedefName(): - needs to produce function-pointer-type name w/ original name Fix JavaEmitter's Function/Struct Emission: - needs to create FunctionSymbol w/ original native name, - then rename - preserving the original one.
Diffstat (limited to 'src/java/com/jogamp/gluegen/JavaEmitter.java')
-rw-r--r--src/java/com/jogamp/gluegen/JavaEmitter.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/java/com/jogamp/gluegen/JavaEmitter.java b/src/java/com/jogamp/gluegen/JavaEmitter.java
index 9665182..7ffa88d 100644
--- a/src/java/com/jogamp/gluegen/JavaEmitter.java
+++ b/src/java/com/jogamp/gluegen/JavaEmitter.java
@@ -1151,9 +1151,11 @@ public class JavaEmitter implements GlueEmitter {
System.err.printf("SE.ac.%02d: %s / %s, %s%n", (i+1), field, cfgFieldName1, fieldType.getDebugString());
}
if (fieldType.isFunctionPointer()) {
+ final FunctionSymbol func = new FunctionSymbol(field.getName(), fieldType.asPointer().getTargetType().asFunction());
+ func.rename(renamed); // null is OK
generateFunctionPointerCode(methodBindingSet, javaWriter, jniWriter, structCTypeName, structClassPkgName,
containingCType, containingJType, i,
- new FunctionSymbol(fieldName, fieldType.asPointer().getTargetType().asFunction()), cfgFieldName1);
+ func, cfgFieldName1);
} else if (fieldType.isCompound()) {
// FIXME: will need to support this at least in order to
// handle the union in jawt_Win32DrawingSurfaceInfo (fabricate a name?)