I have some questions about this example:
protocol A { a; }
protocol B extends A { b; }
class C implements B {
[A.a]() {}
[B.b]() {}
}
In this example, implementing B seems to require referencing A. I was wondering if it made sense to copy over the properties of A to B:
protocol A { a; }
protocol B extends A { b; }
class C implements B {
[B.a]() {} // copy A.a to B.a
[B.b]() {}
}
If not, does that mean that B can also have it's own symbol named a?
protocol A { a; }
protocol B extends A { a; b; }
class C implements B {
[A.a]() {}
[B.a]() {}
[B.b]() {}
}
Or should that be an early error?
I have some questions about this example:
In this example, implementing
Bseems to require referencing A. I was wondering if it made sense to copy over the properties of A to B:If not, does that mean that
Bcan also have it's own symbol nameda?Or should that be an early error?