[gobject-introspection/fix-c4098-warnings: 7/7] gi[callable|type]info.c: Avoid MSVC C4098 warnings




commit 0b168b45ef312ac6b6e1df563bcb8f91172d59d5
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Thu Mar 10 18:11:05 2022 +0800

    gi[callable|type]info.c: Avoid MSVC C4098 warnings
    
    We attempted to return a value in void-return-type functions in both
    gicallableinfo.c and gitypeinfo.c, so avoid that since that will trigger a
    C4098 warning on Visual Studio, which is considered an error if we are building
    against an installed version of GLib 2.68.x or later.
    
    This will fix builds against GLib-2.68.x and later on Visual Studio.

 girepository/gicallableinfo.c | 4 ++--
 girepository/gitypeinfo.c     | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/girepository/gicallableinfo.c b/girepository/gicallableinfo.c
index 790c3d6a..8b9fb3da 100644
--- a/girepository/gicallableinfo.c
+++ b/girepository/gicallableinfo.c
@@ -574,8 +574,8 @@ gi_type_info_extract_ffi_return_value (GITypeInfo                  *return_info,
       g_base_info_unref (interface_info);
     }
 
-  return gi_type_tag_extract_ffi_return_value (return_tag, interface_type,
-                                               ffi_value, arg);
+  gi_type_tag_extract_ffi_return_value (return_tag, interface_type,
+                                        ffi_value, arg);
 }
 
 /**
diff --git a/girepository/gitypeinfo.c b/girepository/gitypeinfo.c
index 6aa10e05..f3c59658 100644
--- a/girepository/gitypeinfo.c
+++ b/girepository/gitypeinfo.c
@@ -470,8 +470,8 @@ g_type_info_argument_from_hash_pointer (GITypeInfo *info,
                                         GIArgument *arg)
 {
     GITypeTag storage_type = g_type_info_get_storage_type (info);
-    return gi_type_tag_argument_from_hash_pointer (storage_type, hash_pointer,
-                                                   arg);
+    gi_type_tag_argument_from_hash_pointer (storage_type, hash_pointer,
+                                            arg);
 }
 
 /**


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]