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

Add the initial draft for inference-using-bounds #4140

Merged
merged 22 commits into from
Dec 3, 2024

Conversation

chloestefantsova
Copy link
Contributor

This PR adds the initial draft for the inference-using-bounds language feature specification.

Copy link
Member

@stereotype441 stereotype441 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, but since I'm relatively inexperienced in writing specs, I'm going to tag in @eernstg as another reviewer

@stereotype441 stereotype441 requested a review from eernstg October 24, 2024 21:18
@kevmoo
Copy link
Member

kevmoo commented Oct 25, 2024

Cool to see the inline mermaid!

Copy link
Member

@eernstg eernstg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

I think the actual feature specification is the modification of 'inference.md', and the other document is all about background and motivation.

So I'm suggesting that feature-specification.md is renamed (perhaps to design-document.md).

With this rename in place, it's perfectly fine that the document doesn't specify the precise rules, and that it is completely example-driven.

I do suggest, though, that the formal update (that is, the new text in inference.md) is mentioned up front in the design document, such that (1) readers will still know what the diff is without needing to track down the git update where inference.md was updated, and (2) the design document is explicit about the precise thing that it's motivating and explaining. This would just be a short section.

Copy link
Member

@eernstg eernstg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let me just do LGTM, to make sure I am not blocking anything.

@sgrekhov
Copy link
Contributor

sgrekhov commented Nov 1, 2024

Github doesn't allow to comment that line, so I'm writing it here. File inference.md, informal section on lines L745-746.

The bound of a type variable is only included as a constraint when the
choice of type for that type variable is about to be frozen.

Seems that it should be updated as well.

@chloestefantsova
Copy link
Contributor Author

Github doesn't allow to comment that line, so I'm writing it here. File inference.md, informal section on lines L745-746.

The bound of a type variable is only included as a constraint when the
choice of type for that type variable is about to be frozen.

Seems that it should be updated as well.

Thanks for spotting that! The informal section should be updated, tool.

Copy link
Member

@eernstg eernstg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@chloestefantsova
Copy link
Contributor Author

Thanks for the review and the comments, everybody!

@chloestefantsova chloestefantsova merged commit cdee9bc into main Dec 3, 2024
3 checks passed
@chloestefantsova chloestefantsova deleted the inference-using-bounds branch December 3, 2024 10:14
Copy link

@Kutter07 Kutter07 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(accepted/future-releases/3009-inference-using-bounds/design-document.md )+
(resources/type-system/inference.md)

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.

6 participants