Skip to content

Instantly share code, notes, and snippets.

@brandondiamond
Created June 11, 2020 15:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brandondiamond/a5359294a67ea186ecb7773f8764feea to your computer and use it in GitHub Desktop.
Save brandondiamond/a5359294a67ea186ecb7773f8764feea to your computer and use it in GitHub Desktop.
Simpler reproduction of self-collision bug
class Pair<T extends Pair<T, S>, S extends Pair<T, S>> {}
mixin BrokenMixin<T extends Pair<T, S>, S extends Pair<T, S>> {
void broken<V extends Pair<V, W>, W extends Pair<V, W>>([void Function(T, V) func]) {}
}
class Example with BrokenMixin<Null, Null> {}
main() {
Example().broken<Null, Null>();
}
// "Null" passed for convenience; any valid type will trigger the bug.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment