Skip to content

protected List<T > getFieldOrder() generated code cause compilation issues in Java 1.8 #120

@bakkiaraj

Description

@bakkiaraj

I am using JNAerator for libclang JNA interface creation. Here is the command used,
java -Xmx1300m -jar jnaerator-0.12-shaded.jar -arch win32 libx86/libclang.dll -library libclang -libFile libx86/libclang.dll -I./inc/ ./inc/clang-c/Index.h ./inc/clang-c/Platform.h ./inc/clang-c/CXErrorCode.h ./inc/clang-c/CXString.h ./inc/clang-c/CXCompilationDatabase.h ./inc/clang-c/Documentation.h ./inc/clang-c/BuildSystem.h -mode Directory -f -runtime JNA -o ./generated -rootPackage com.np -skipDeprecated -preferJavac -v
The generated code has multiple compilation issues , All of them were are "List" changes to "List", I had done the changes manually.

Ex:
public class CXComment extends Structure {
/** C type : const void* /
public Pointer ASTNode;
/
* C type : CXTranslationUnit /
public CXTranslationUnit TranslationUnit;
public CXComment() {
super();
}
protected List getFieldOrder() {
return Arrays.asList("ASTNode", "TranslationUnit");
}
/
*
* @param ASTNode C type : const void*

* @param TranslationUnit C type : CXTranslationUnit
*/
public CXComment(Pointer ASTNode, CXTranslationUnit TranslationUnit) {
super();
this.ASTNode = ASTNode;
this.TranslationUnit = TranslationUnit;
}
public CXComment(Pointer peer) {
super(peer);
}
public static class ByReference extends CXComment implements Structure.ByReference {

};
public static class ByValue extends CXComment implements Structure.ByValue {
	
};

}

Please update the code in a way that List is used in the generated code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions