interrogate: fix regression with setter of MAKE_PROPERTY2

See also tobspr/RenderPipeline#86
This commit is contained in:
rdb 2017-10-17 21:18:51 +02:00
parent bb60e8c373
commit dee8d83998
2 changed files with 4 additions and 4 deletions

View File

@ -4420,9 +4420,9 @@ yyreduce:
make_property->_has_function = hasser->as_function_group();
}
CPPDeclaration *setter = (yyvsp[-6].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
CPPDeclaration *setter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
yyerror("reference to non-existent or invalid setter: " + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
yyerror("reference to non-existent or invalid setter: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
} else {
make_property->_set_function = setter->as_function_group();
}

View File

@ -793,9 +793,9 @@ declaration:
make_property->_has_function = hasser->as_function_group();
}
CPPDeclaration *setter = $7->find_symbol(current_scope, global_scope, current_lexer);
CPPDeclaration *setter = $9->find_symbol(current_scope, global_scope, current_lexer);
if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
yyerror("reference to non-existent or invalid setter: " + $7->get_fully_scoped_name(), @7);
yyerror("reference to non-existent or invalid setter: " + $9->get_fully_scoped_name(), @9);
} else {
make_property->_set_function = setter->as_function_group();
}