We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider:
@pub trait Iterator { fun next(): Option[Int32]; // this should be made generic }
Ideally we would have:
@pub trait Iterator[T] { fun next(): Option[T]; }
Which compiles, but a trait impls like ...
impl Iterator[Int32] for NoInt32Iterator { fun next(): Option[Int32] = None[Int32]; }
... fails compilation with:
return types `Option[Int32]` and `Option[T]` do not match
Feels like we forget specializing the return type.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Consider:
Ideally we would have:
Which compiles, but a trait impls like ...
... fails compilation with:
Feels like we forget specializing the return type.
The text was updated successfully, but these errors were encountered: