-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Explicitly include an enum by name (#33)
* Add ability to explicitly include an enum by name * Reference libclang if it exists in `lib` * Keep old behavior of field names for newer versions of Clang
- Loading branch information
1 parent
7c7f543
commit b00c09a
Showing
18 changed files
with
276 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,6 @@ obj/ | |
/artifacts/ | ||
src/c/tests/**/ffi/*.json | ||
src/c/tests/**/ffi-x/*.json | ||
|
||
# Native library files | ||
lib/*.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"inputFilePath": "./main.c", | ||
"userIncludeDirectories": [ | ||
"../../../production/ffi_helper/include" | ||
], | ||
"ignoredIncludeFiles": [ | ||
"../../../production/ffi_helper/include/ffi_helper.h" | ||
], | ||
"includedNames": [ | ||
"enum_implicit" | ||
], | ||
"targetPlatforms": { | ||
"windows": { | ||
"i686-pc-windows-msvc": {}, | ||
"x86_64-pc-windows-msvc": {}, | ||
"aarch64-pc-windows-msvc": {} | ||
}, | ||
"macos": { | ||
"i686-apple-darwin": {}, | ||
"aarch64-apple-darwin": {}, | ||
"x86_64-apple-darwin": {}, | ||
"aarch64-apple-ios": {} | ||
}, | ||
"linux": { | ||
"i686-unknown-linux-gnu": {}, | ||
"x86_64-unknown-linux-gnu": {}, | ||
"aarch64-unknown-linux-gnu": {} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#include <stdio.h> | ||
#include "ffi_helper.h" | ||
|
||
enum enum_implicit { | ||
ENUM_IMPLICIT_VALUE0 = 0, | ||
ENUM_IMPLICIT_VALUE1 = 255 | ||
} enum_implicit; | ||
|
||
FFI_API_DECL int function_implicit_enum(int value) | ||
{ | ||
return ENUM_IMPLICIT_VALUE1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.