diff options
| author | Yusuke Endoh <mame@ruby-lang.org> | 2024-11-29 11:51:29 +0900 |
|---|---|---|
| committer | Yusuke Endoh <mame@ruby-lang.org> | 2024-11-29 12:27:04 +0900 |
| commit | a32981b6b89c23c7b650c6b1d1309e86856735ff (patch) | |
| tree | 77110b8d6106eccb3936e0edef6a3f5e17f3c7fb /node.c | |
| parent | 43dd9c721f9bec8aeeaf6c6ca98313cb0e97b510 (diff) | |
Remove a useless check
Here `nb` should never be NULL. If it were, the following
`nb->buffer_list` would be strange.
A follow-up to ddd8da4b6ba3dfcca21ca710e7cef2fa3b9632d7
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/12208
Diffstat (limited to 'node.c')
| -rw-r--r-- | node.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -225,7 +225,7 @@ free_ast_value(rb_ast_t *ast, void *ctx, NODE *node) static void rb_node_buffer_free(rb_ast_t *ast, node_buffer_t *nb) { - if (nb && nb->tokens) { + if (nb->tokens) { parser_tokens_free(ast, nb->tokens); } iterate_node_values(ast, &nb->buffer_list, free_ast_value, NULL); |
