]> gitweb.factorcode.org Git - factor.git/commitdiff
vm: Fix some really minor warnings.
authorDoug Coleman <doug.coleman@gmail.com>
Sat, 28 Jul 2018 02:35:55 +0000 (21:35 -0500)
committerDoug Coleman <doug.coleman@gmail.com>
Sat, 28 Jul 2018 02:35:55 +0000 (21:35 -0500)
vm/ffi_test.c
vm/ffi_test.h
vm/quotations.hpp

index 4bf5e70f3ec30e30a0384bd38a942d7f9cadde36..1927a8d9881ee7e5df5b009f44d37e7ed96301eb 100644 (file)
@@ -84,7 +84,10 @@ FACTOR_STDCALL(struct bar) ffi_test_19(long x, long y, long z) {
 }
 
 void ffi_test_20(double x1, double x2, double x3, double y1, double y2,
-                 double y3, double z1, double z2, double z3) {}
+                 double y3, double z1, double z2, double z3) {
+  (void) x1, (void) x2, (void) x3, (void) y1, (void) y2,
+  (void) y3, (void) z1, (void) z2, (void) z3;
+}
 
 long long ffi_test_21(long x, long y) { return (long long) x * (long long) y; }
 
@@ -309,7 +312,7 @@ unsigned long long ffi_test_60(unsigned long long x) {
 /* C99 features */
 #ifndef _MSC_VER
 
-struct bool_and_ptr ffi_test_61() {
+struct bool_and_ptr ffi_test_61(void) {
   struct bool_and_ptr bap;
   bap.b = true;
   bap.ptr = NULL;
@@ -318,14 +321,14 @@ struct bool_and_ptr ffi_test_61() {
 
 #endif
 
-struct uint_pair ffi_test_62() {
+struct uint_pair ffi_test_62(void) {
   struct uint_pair uip;
   uip.a = 0xabcdefab;
   uip.b = 0x12345678;
   return uip;
 }
 
-struct ulonglong_pair ffi_test_63() {
+struct ulonglong_pair ffi_test_63(void) {
   struct ulonglong_pair ullp;
   ullp.a = 0xabcdefabcdefabcd;
   ullp.b = 0x1234567891234567;
@@ -360,6 +363,8 @@ void* bug1021_test_1(void* x, int y) {
 }
 
 int bug1021_test_2(int x, char *y, void *z) {
+  (void) x;
+  (void) z;
   return y[0];
 }
 
index c359811e65a9fbf4bb613dd21675843e9195707b..1c7ae7ddb31df845984f0de68dc1f6a7622058b4 100644 (file)
@@ -161,7 +161,7 @@ struct test_struct_16 {
 
 FACTOR_EXPORT struct test_struct_16 ffi_test_43(float x, int a);
 
-FACTOR_EXPORT struct test_struct_14 ffi_test_44();
+FACTOR_EXPORT struct test_struct_14 ffi_test_44(void);
 
 /* C99 features */
 #ifndef _MSC_VER
@@ -211,7 +211,7 @@ struct bool_and_ptr {
     void* ptr;
 };
 
-FACTOR_EXPORT struct bool_and_ptr ffi_test_61();
+FACTOR_EXPORT struct bool_and_ptr ffi_test_61(void);
 
 #endif
 
@@ -220,14 +220,14 @@ struct uint_pair {
        unsigned int b;
 };
 
-FACTOR_EXPORT struct uint_pair ffi_test_62();
+FACTOR_EXPORT struct uint_pair ffi_test_62(void);
 
 struct ulonglong_pair {
        unsigned long long a;
        unsigned long long b;
 };
 
-FACTOR_EXPORT struct ulonglong_pair ffi_test_63();
+FACTOR_EXPORT struct ulonglong_pair ffi_test_63(void);
 
 FACTOR_EXPORT int ffi_test_64(int n, ...);
 FACTOR_EXPORT double ffi_test_65(int n, ...);
index dd80c94882db75fe4fe7e2d1356253fc4d90aed4..3c659126dc0ddf53e64a70403dc6be449a73bf27 100644 (file)
@@ -10,7 +10,6 @@ struct quotation_jit : public jit {
         elements(false_object, vm),
         compiling(compiling),
         relocate(relocate) {}
-  ;
 
   cell nth(cell index);
   void init_quotation(cell quot);