-
Notifications
You must be signed in to change notification settings - Fork 83
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
jnaerator with bridj: fixing problem with varargs and variable named …
…with reserved java keywords Fixing incorrect generation for bridj backend mainly for varargs * added tests for the problem of varargs (also for reserved name) * fixing problem by taking inspiration from the jna backed version === Copyright Transfert Declaration === I, Rémi Emonet, declare being the only author of the current commit. I fully transfer the copyright for this patch to Olivier Chafik for an integration as part of the nativelibs4java project provided it uses opensource licenses such as BSD license, Apache license, MIT license or any equivalent licensing scheme.
- Loading branch information
Rémi Émonet
committed
Aug 9, 2011
1 parent
1a0c9c7
commit 74b59d5
Showing
2 changed files
with
36 additions
and
6 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
15 changes: 15 additions & 0 deletions
15
...or/src/test/resources/com/ochafik/lang/jnaerator/tests/function varargs and reserved.test
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,15 @@ | ||
void varargAndReserved(int transient, ...); | ||
-- | ||
#runtime(JNAerator) | ||
import test.*; | ||
import static test.TestLibrary.*; | ||
|
||
INSTANCE.varargAndReserved(1); | ||
INSTANCE.varargAndReserved(1,(Pointer)null); | ||
-- | ||
#runtime(BridJ) | ||
import test.*; | ||
import static test.TestLibrary.*; | ||
|
||
varargAndReserved(1); | ||
varargAndReserved(1,(Pointer)null); |