Skip to content
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

cmd/compile: constraint satisfaction errors use "implements" instead of "satisfies" #57564

Closed
griesemer opened this issue Jan 3, 2023 · 4 comments
Assignees
Labels
compiler/runtime Issues related to the Go compiler and/or runtime. FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@griesemer
Copy link
Contributor

Per the latest spec, we now distinguish between interface implementation and constraint satisfaction.

However, currently the compiler reports constraint satisfaction errors with the phrase "cannot implement" or "does not implement" instead of "cannot satisfy" or "does not satisfy".

Not necessarily a release blocker but would be good to fix ASAP.

@griesemer griesemer added the NeedsFix The path to resolution is known, but the work has not been done. label Jan 3, 2023
@griesemer griesemer added this to the Go1.20 milestone Jan 3, 2023
@griesemer griesemer self-assigned this Jan 3, 2023
@gopherbot gopherbot added the compiler/runtime Issues related to the Go compiler and/or runtime. label Jan 3, 2023
@griesemer
Copy link
Contributor Author

cc: @findleyr

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/460396 mentions this issue: cmd/compile: use "satisfies" (not "implements") for constraint errors

@griesemer
Copy link
Contributor Author

griesemer commented Jan 4, 2023

cc: @golang/release to decide if the CL above is acceptable to submit for 1.20. The change only affects error messages, but of those it affects virtually every error message about constraint satisfaction. It would be good to use the same language in those messages as is now used in the spec.

@heschi
Copy link
Contributor

heschi commented Jan 4, 2023

Fine by us; seems like a straightforward bug fix even if it's not so critical.

@golang golang locked and limited conversation to collaborators Jan 4, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
compiler/runtime Issues related to the Go compiler and/or runtime. FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

3 participants