Fix cast to smaller integer type warning in glib/gscanner.c

glib/gscanner.c:1681:13: warning: cast to smaller integer type 'GTokenType' from 'gpointer' (aka 'void *')
        *token_p = (GTokenType) value_p->v_symbol;
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This commit is contained in:
Emmanuel Fleury 2021-04-28 13:04:49 +02:00
parent 83d46f6a0a
commit 9656e606d2

View File

@ -1678,7 +1678,7 @@ g_scanner_get_token_i (GScanner *scanner,
case G_TOKEN_SYMBOL:
if (scanner->config->symbol_2_token)
*token_p = (GTokenType) value_p->v_symbol;
*token_p = (GTokenType) ((size_t) value_p->v_symbol);
break;
case G_TOKEN_BINARY: