[vala/staging] girparser: TypeSymbol of accessor must match the property
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala/staging] girparser: TypeSymbol of accessor must match the property
- Date: Thu, 3 Jun 2021 10:11:44 +0000 (UTC)
commit 91b0fd6e449494118650dcd445a8a6c2090b7f35
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Fri May 28 20:03:54 2021 +0200
girparser: TypeSymbol of accessor must match the property
vala/valagirparser.vala | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/vala/valagirparser.vala b/vala/valagirparser.vala
index 2345c355e..0b9ae9555 100644
--- a/vala/valagirparser.vala
+++ b/vala/valagirparser.vala
@@ -1059,7 +1059,7 @@ public class Vala.GirParser : CodeVisitor {
getter.process (parser);
if (m.return_type is VoidType ||
m.get_parameters().size != 0 || m.tree_can_fail) {
prop.set_attribute ("NoAccessorMethod", true);
- } else {
+ } else if (prop.property_type.type_symbol ==
m.return_type.type_symbol) {
if (getter.name == name) {
foreach (var node in colliding) {
if (node.symbol is Method) {
@@ -1087,7 +1087,7 @@ public class Vala.GirParser : CodeVisitor {
if (!(m.return_type is VoidType || m.return_type is
BooleanType) || m.get_parameters ().size != 1 || m.tree_can_fail) {
prop.set_attribute ("NoAccessorMethod", true);
prop.set_attribute ("ConcreteAccessor",
false);
- } else {
+ } else if (prop.property_type.type_symbol ==
m.get_parameters()[0].variable_type.type_symbol) {
prop.set_accessor.value_type.value_owned =
m.get_parameters()[0].variable_type.value_owned;
if (prop.get_attribute ("ConcreteAccessor")
!= null && !m.is_abstract && !m.is_virtual && prop.is_abstract) {
prop.set_attribute
("ConcreteAccessor", true);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]