nitlanguage
/
nit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
src: move pseudo-toplevel methods from Object
[nit.git]
/
tests
/
test_ffi_c_primitives.nit
diff --git
a/tests/test_ffi_c_primitives.nit
b/tests/test_ffi_c_primitives.nit
index
48947b4
..
2295927
100644
(file)
--- a/
tests/test_ffi_c_primitives.nit
+++ b/
tests/test_ffi_c_primitives.nit
@@
-28,6
+28,10
@@
fun multiply_by_100(v: Float): Float `{
return v * 100;
`}
return v * 100;
`}
+fun plus_0x10(v: Byte): Byte `{
+ return v + 0x10;
+`}
+
fun print_ns(s: NativeString) `{
printf("%s\n", s);
`}
fun print_ns(s: NativeString) `{
printf("%s\n", s);
`}
@@
-41,6
+45,6
@@
print plus_1000(1234)
print multiply_by_100(123.45)
print multiply_by_100(123.45)
-print multiply_by_100( 123.45 )
+print plus_0x10(0x2u8)
print_ns("hello world".to_cstring)
print_ns("hello world".to_cstring)