summaryrefslogtreecommitdiff
path: root/ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c
diff options
context:
space:
mode:
authortduehr <tduehr@gmail.com>2015-03-19 16:44:33 -0700
committertduehr <tduehr@gmail.com>2015-06-17 09:01:47 -0500
commite9d07620ae8ac090863998d22ab7ca0db9cd1e89 (patch)
treeba0c75a8e11e88123926cb9817a3bb0a7c1b157b /ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c
parent194784d60f53e242a8aab88c216126785dc047dd (diff)
downloadffi-libffi-3.2.1.tar.gz
update libffilibffi-3.2.1
Diffstat (limited to 'ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c')
-rw-r--r--ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c b/ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c
index 235ab44..62f2cae 100644
--- a/ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c
+++ b/ext/ffi_c/libffi/testsuite/libffi.call/cls_ulonglong.c
@@ -11,7 +11,7 @@
static void cls_ret_ulonglong_fn(ffi_cif* cif __UNUSED__, void* resp,
void** args, void* userdata __UNUSED__)
{
- *(unsigned long long *)resp= *(unsigned long long *)args[0];
+ *(unsigned long long *)resp= 0xfffffffffffffffLL ^ *(unsigned long long *)args[0];
printf("%" PRIuLL ": %" PRIuLL "\n",*(unsigned long long *)args[0],
*(unsigned long long *)(resp));
@@ -34,14 +34,14 @@ int main (void)
&ffi_type_uint64, cl_arg_types) == FFI_OK);
CHECK(ffi_prep_closure_loc(pcl, &cif, cls_ret_ulonglong_fn, NULL, code) == FFI_OK);
res = (*((cls_ret_ulonglong)code))(214LL);
- /* { dg-output "214: 214" } */
+ /* { dg-output "214: 1152921504606846761" } */
printf("res: %" PRIdLL "\n", res);
- /* { dg-output "\nres: 214" } */
+ /* { dg-output "\nres: 1152921504606846761" } */
res = (*((cls_ret_ulonglong)code))(9223372035854775808LL);
- /* { dg-output "\n9223372035854775808: 9223372035854775808" } */
+ /* { dg-output "\n9223372035854775808: 8070450533247928831" } */
printf("res: %" PRIdLL "\n", res);
- /* { dg-output "\nres: 9223372035854775808" } */
+ /* { dg-output "\nres: 8070450533247928831" } */
exit(0);
}