| 1 |
signal hello |
| 2 |
|
| 3 |
func get_signal() -> Signal: |
| 4 |
return hello |
| 5 |
|
| 6 |
class A: |
| 7 |
signal hello |
| 8 |
|
| 9 |
func get_signal() -> Signal: |
| 10 |
return hello |
| 11 |
|
| 12 |
class B: |
| 13 |
signal hello |
| 14 |
|
| 15 |
func get_signal() -> Signal: |
| 16 |
return hello |
| 17 |
|
| 18 |
class C extends A.B: |
| 19 |
func get_signal() -> Signal: |
| 20 |
return hello |
| 21 |
|
| 22 |
func test(): |
| 23 |
var a: = A.new() |
| 24 |
var b: = A.B.new() |
| 25 |
var c: = C.new() |
| 26 |
|
| 27 |
var hello_a_result: = hello == a.get_signal() |
| 28 |
var hello_b_result: = hello == b.get_signal() |
| 29 |
var hello_c_result: = hello == c.get_signal() |
| 30 |
var a_b_result: = a.get_signal() == b.get_signal() |
| 31 |
var a_c_result: = a.get_signal() == c.get_signal() |
| 32 |
var b_c_result: = b.get_signal() == c.get_signal() |
| 33 |
var c_c_result: = c.get_signal() == c.get_signal() |
| 34 |
|
| 35 |
print("hello == A.hello? %s" % hello_a_result) |
| 36 |
print("hello == A.B.hello? %s" % hello_b_result) |
| 37 |
print("hello == C.hello? %s" % hello_c_result) |
| 38 |
print("A.hello == A.B.hello? %s" % a_b_result) |
| 39 |
print("A.hello == C.hello? %s" % a_c_result) |
| 40 |
print("A.B.hello == C.hello? %s" % b_c_result) |
| 41 |
print("C.hello == C.hello? %s" % c_c_result) |