[Groonga-commit] groonga/groonga [master] clang: suppress a warning

Back to archive index

null+****@clear***** null+****@clear*****
Fri Aug 10 18:28:39 JST 2012


Kouhei Sutou	2012-08-10 18:28:39 +0900 (Fri, 10 Aug 2012)

  New Revision: 4a7097fe46d5b45de50b5780dab49279ead4867f
  https://github.com/groonga/groonga/commit/4a7097fe46d5b45de50b5780dab49279ead4867f

  Log:
    clang: suppress a warning
    
    table.c:195:7: warning: expression result unused [-Wunused-value]
      if (TEXT_VALUE_LEN(VAR(2)) == 0) {
          ^~~~~~~~~~~~~~~~~~~~~~
    table.c:28:27: note: expanded from macro 'TEXT_VALUE_LEN'
    #define TEXT_VALUE_LEN(x) GRN_TEXT_VALUE(x), GRN_TEXT_LEN(x)
                              ^
    ../../include/groonga.h:2205:29: note: expanded from macro 'GRN_TEXT_VALUE'
    #define GRN_TEXT_VALUE(obj) GRN_BULK_HEAD(obj)
                                ^
    ../../include/groonga.h:2077:19: note: expanded from macro 'GRN_BULK_HEAD'
       ? ((bulk)->u.b.head)\
          ~~~~~~~~~~~ ^~~~

  Modified files:
    plugins/table/table.c

  Modified: plugins/table/table.c (+1 -1)
===================================================================
--- plugins/table/table.c    2012-08-10 18:21:22 +0900 (8312728)
+++ plugins/table/table.c    2012-08-10 18:28:39 +0900 (9eeb486)
@@ -192,7 +192,7 @@ command_filter(grn_ctx *ctx, int nargs, grn_obj **args, grn_user_data *user_data
         (int)GRN_TEXT_LEN(VAR(1)), GRN_TEXT_VALUE(VAR(1)));
     goto exit;
   }
-  if (TEXT_VALUE_LEN(VAR(2)) == 0) {
+  if (GRN_TEXT_LEN(VAR(2)) == 0) {
     ERR(GRN_INVALID_ARGUMENT, "missing mandatory argument: operator");
     goto exit;
   } else {
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index