Created
June 10, 2020 23:33
-
-
Save brandondiamond/423c87736f4d2fe506afcbb13550f24e to your computer and use it in GitHub Desktop.
Reproducing incompatible signature bug
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Built<T extends Built<T, S>, S extends Builder<T, S>> { | |
} | |
class Builder<T extends Built<T, S>, S extends Builder<T, S>> { | |
} | |
class StatefulWidget { | |
} | |
class State<T extends StatefulWidget> { | |
} | |
mixin BrokenMixin<T extends Built<T, S>, S extends Builder<T, S>, U extends StatefulWidget> on State<U> { | |
void broken<V extends Built<V, W>, W extends Builder<V, W>>([void Function(T, V) func]) { | |
} | |
} | |
class ExampleBuilt extends Built<ExampleBuilt, ExampleBuilder> { | |
} | |
class ExampleBuilder extends Builder<ExampleBuilt, ExampleBuilder> { | |
} | |
class ExampleWidget extends StatefulWidget { | |
} | |
class ExampleWidgetState extends State<ExampleWidget> with BrokenMixin<ExampleBuilt, ExampleBuilder, ExampleWidget> { | |
void callBroken() { | |
broken<ExampleBuilt, ExampleBuilder>(); | |
} | |
} | |
main() { | |
final example = ExampleWidgetState(); | |
example.callBroken(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment