We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
context_pop
1 parent 157be4f commit fe85b59Copy full SHA for fe85b59
src/yarp.c
@@ -4902,14 +4902,9 @@ context_push(yp_parser_t *parser, yp_context_t context) {
4902
4903
static void
4904
context_pop(yp_parser_t *parser) {
4905
- if (parser->current_context->prev == NULL) {
4906
- free(parser->current_context);
4907
- parser->current_context = NULL;
4908
- } else {
4909
- yp_context_node_t *prev = parser->current_context->prev;
4910
4911
- parser->current_context = prev;
4912
- }
+ yp_context_node_t *prev = parser->current_context->prev;
+ free(parser->current_context);
+ parser->current_context = prev;
4913
}
4914
4915
static bool
0 commit comments