From dee8d83998b4cd863c9b1071b5f5cc8d4b9e8ad0 Mon Sep 17 00:00:00 2001 From: rdb Date: Tue, 17 Oct 2017 21:18:51 +0200 Subject: [PATCH] interrogate: fix regression with setter of MAKE_PROPERTY2 See also tobspr/RenderPipeline#86 --- dtool/src/cppparser/cppBison.cxx.prebuilt | 4 ++-- dtool/src/cppparser/cppBison.yxx | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dtool/src/cppparser/cppBison.cxx.prebuilt b/dtool/src/cppparser/cppBison.cxx.prebuilt index c8b8754035..f93ae67fdd 100644 --- a/dtool/src/cppparser/cppBison.cxx.prebuilt +++ b/dtool/src/cppparser/cppBison.cxx.prebuilt @@ -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(); } diff --git a/dtool/src/cppparser/cppBison.yxx b/dtool/src/cppparser/cppBison.yxx index 00e5c87397..1bf3f3860a 100644 --- a/dtool/src/cppparser/cppBison.yxx +++ b/dtool/src/cppparser/cppBison.yxx @@ -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(); }