Skip to content

[SR-7984] Constraint to concrete type using : should offer a fixit #18734

New issue

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

Conversation

enomoto
Copy link

@enomoto enomoto commented Aug 15, 2018

This PR adds fixit for constraint to concrete type using :.

Resolves SR-7984.

@jrose-apple jrose-apple requested a review from DougGregor August 15, 2018 21:27
@jrose-apple
Copy link
Contributor

Thanks, Kenta! But I'm not sure if we want the fix-it directly on the error, as opposed to on a note that explains what it would do instead. That'd be something like "use '==' to require 'T' to be 'Int'".

@slavapestov
Copy link
Contributor

And if you want to be really fancy, don't offer the fixit if the subject type is a GenericTypeParamType, unless you're in an extension.

@CodaFi
Copy link
Contributor

CodaFi commented Nov 18, 2019

Superseded by #22152. Thanks for your efforts here!

@CodaFi CodaFi closed this Nov 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants