@@ -5662,7 +5662,7 @@ pm_lambda_node_create(
56625662 */
56635663static pm_local_variable_and_write_node_t *
56645664pm_local_variable_and_write_node_create(pm_parser_t *parser, pm_node_t *target, const pm_token_t *operator, pm_node_t *value, pm_constant_id_t name, uint32_t depth) {
5665- assert(PM_NODE_TYPE_P(target, PM_LOCAL_VARIABLE_READ_NODE) || PM_NODE_TYPE_P(target, PM_CALL_NODE));
5665+ assert(PM_NODE_TYPE_P(target, PM_LOCAL_VARIABLE_READ_NODE) || PM_NODE_TYPE_P(target, PM_IT_LOCAL_VARIABLE_READ_NODE) || PM_NODE_TYPE_P(target, PM_CALL_NODE));
56665666 assert(operator->type == PM_TOKEN_AMPERSAND_AMPERSAND_EQUAL);
56675667 pm_local_variable_and_write_node_t *node = PM_NODE_ALLOC(parser, pm_local_variable_and_write_node_t);
56685668
@@ -5717,7 +5717,7 @@ pm_local_variable_operator_write_node_create(pm_parser_t *parser, pm_node_t *tar
57175717 */
57185718static pm_local_variable_or_write_node_t *
57195719pm_local_variable_or_write_node_create(pm_parser_t *parser, pm_node_t *target, const pm_token_t *operator, pm_node_t *value, pm_constant_id_t name, uint32_t depth) {
5720- assert(PM_NODE_TYPE_P(target, PM_LOCAL_VARIABLE_READ_NODE) || PM_NODE_TYPE_P(target, PM_CALL_NODE));
5720+ assert(PM_NODE_TYPE_P(target, PM_LOCAL_VARIABLE_READ_NODE) || PM_NODE_TYPE_P(target, PM_IT_LOCAL_VARIABLE_READ_NODE) || PM_NODE_TYPE_P(target, PM_CALL_NODE));
57215721 assert(operator->type == PM_TOKEN_PIPE_PIPE_EQUAL);
57225722 pm_local_variable_or_write_node_t *node = PM_NODE_ALLOC(parser, pm_local_variable_or_write_node_t);
57235723
@@ -21218,6 +21218,17 @@ parse_expression_infix(pm_parser_t *parser, pm_node_t *node, pm_binding_power_t
2121821218 pm_node_destroy(parser, node);
2121921219 return result;
2122021220 }
21221+ case PM_IT_LOCAL_VARIABLE_READ_NODE: {
21222+ pm_constant_id_t name = pm_parser_local_add_constant(parser, "it", 2);
21223+ parser_lex(parser);
21224+
21225+ pm_node_t *value = parse_assignment_value(parser, previous_binding_power, binding_power, accepts_command_call, PM_ERR_EXPECT_EXPRESSION_AFTER_AMPAMPEQ, (uint16_t) (depth + 1));
21226+ pm_node_t *result = (pm_node_t *) pm_local_variable_and_write_node_create(parser, node, &token, value, name, 0);
21227+
21228+ parse_target_implicit_parameter(parser, node);
21229+ pm_node_destroy(parser, node);
21230+ return result;
21231+ }
2122121232 case PM_LOCAL_VARIABLE_READ_NODE: {
2122221233 if (pm_token_is_numbered_parameter(node->location.start, node->location.end)) {
2122321234 PM_PARSER_ERR_FORMAT(parser, node->location.start, node->location.end, PM_ERR_PARAMETER_NUMBERED_RESERVED, node->location.start);
@@ -21341,6 +21352,17 @@ parse_expression_infix(pm_parser_t *parser, pm_node_t *node, pm_binding_power_t
2134121352 pm_node_destroy(parser, node);
2134221353 return result;
2134321354 }
21355+ case PM_IT_LOCAL_VARIABLE_READ_NODE: {
21356+ pm_constant_id_t name = pm_parser_local_add_constant(parser, "it", 2);
21357+ parser_lex(parser);
21358+
21359+ pm_node_t *value = parse_assignment_value(parser, previous_binding_power, binding_power, accepts_command_call, PM_ERR_EXPECT_EXPRESSION_AFTER_PIPEPIPEEQ, (uint16_t) (depth + 1));
21360+ pm_node_t *result = (pm_node_t *) pm_local_variable_or_write_node_create(parser, node, &token, value, name, 0);
21361+
21362+ parse_target_implicit_parameter(parser, node);
21363+ pm_node_destroy(parser, node);
21364+ return result;
21365+ }
2134421366 case PM_LOCAL_VARIABLE_READ_NODE: {
2134521367 if (pm_token_is_numbered_parameter(node->location.start, node->location.end)) {
2134621368 PM_PARSER_ERR_FORMAT(parser, node->location.start, node->location.end, PM_ERR_PARAMETER_NUMBERED_RESERVED, node->location.start);
@@ -21474,6 +21496,17 @@ parse_expression_infix(pm_parser_t *parser, pm_node_t *node, pm_binding_power_t
2147421496 pm_node_destroy(parser, node);
2147521497 return result;
2147621498 }
21499+ case PM_IT_LOCAL_VARIABLE_READ_NODE: {
21500+ pm_constant_id_t name = pm_parser_local_add_constant(parser, "it", 2);
21501+ parser_lex(parser);
21502+
21503+ pm_node_t *value = parse_assignment_value(parser, previous_binding_power, binding_power, accepts_command_call, PM_ERR_EXPECT_EXPRESSION_AFTER_OPERATOR, (uint16_t) (depth + 1));
21504+ pm_node_t *result = (pm_node_t *) pm_local_variable_operator_write_node_create(parser, node, &token, value, name, 0);
21505+
21506+ parse_target_implicit_parameter(parser, node);
21507+ pm_node_destroy(parser, node);
21508+ return result;
21509+ }
2147721510 case PM_LOCAL_VARIABLE_READ_NODE: {
2147821511 if (pm_token_is_numbered_parameter(node->location.start, node->location.end)) {
2147921512 PM_PARSER_ERR_FORMAT(parser, node->location.start, node->location.end, PM_ERR_PARAMETER_NUMBERED_RESERVED, node->location.start);
0 commit comments