Open
Description
It seems that if 2 mixins declare the same member with different bounds, the type of the latter mixin member must conform to the type first mixin member, which can throw an error even in cases where the class using the mixin is able to satisfy both types.
mixin LongRangeWeapon {}
mixin ExplosionWeapon {}
class Shotgun with LongRangeWeapon, ExplosionWeapon {}
mixin Shooter {
LongRangeWeapon get weapon;
}
mixin Bomber {
ExplosionWeapon get weapon;
}
abstract class Combatant with Shooter, Bomber { // 'Bomber.weapon' ('ExplosionWeapon Function()') isn't a valid override of 'Shooter.weapon' ('LongRangeWeapon Function()')
@override
Shotgun get weapon;
}
expected behavior: There should not be any error as long as the class itself validly satisfies both mixin.