Navigation Menu

Skip to content

Commit

Permalink
clang: suppress a warning
Browse files Browse the repository at this point in the history
Add missing cast.

    lib/token.c:61:19: warning: assigning to 'byte *'
          (aka 'unsigned char *') from 'char *' converts between pointers to integer
          types with different sign [-Wpointer-sign]
      tokenizer->curr = GRN_TEXT_VALUE(str);
                      ^ ~~~~~~~~~~~~~~~~~~~
  • Loading branch information
kou committed Jun 11, 2013
1 parent 4b26c30 commit 3fe67f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/token.c
Expand Up @@ -58,7 +58,7 @@ uvector_init(grn_ctx *ctx, int nargs, grn_obj **args, grn_user_data *user_data)
user_data->ptr = tokenizer;

grn_tokenizer_token_init(ctx, &(tokenizer->token));
tokenizer->curr = GRN_TEXT_VALUE(str);
tokenizer->curr = (byte *)GRN_TEXT_VALUE(str);
tokenizer->tail = tokenizer->curr + GRN_TEXT_LEN(str);
tokenizer->unit = sizeof(grn_id);
return NULL;
Expand Down

0 comments on commit 3fe67f3

Please sign in to comment.