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

[NLL] remove "constant" region variables, report free region errors later #14

Merged
merged 3 commits into from
Nov 13, 2017

Conversation

nikomatsakis
Copy link
Owner

@nikomatsakis nikomatsakis commented Nov 13, 2017

This was rust-lang#45911:

Rather than declaring some region variables to be constant, and reporting errors when they would have to change, we instead populate each free region X with a minimal set of points (the CFG plus end(X)), and then we let inference do its thing. This may add other end(Y) points into X; we can then check after the fact that indeed X: Y holds.

This will be useful when handling closures properly, since we can then propagate some of those constraints in the form of WF-conditions to our creator. This PR doesn't handle any of that yet.

This requires a bit of "blame" detection to find where the bad constraint came from: we are currently using a pretty dumb algorithm. Good place for later expansion.

@nikomatsakis nikomatsakis force-pushed the nll-delay-free-region-error branch from 2c779e2 to 7ff5f1c Compare November 13, 2017 09:51
@nikomatsakis nikomatsakis changed the title report free region errors later [NLL] remove "constant" region variables, report free region errors later Nov 13, 2017
It will be useful later for diagnostics to be able to remember where
things were live.
Rather than declaring some region variables to be constant, and
reporting errors when they would have to change, we instead populate
each free region X with a minimal set of points (the CFG plus end(X)),
and then we let inference do its thing. This may add other `end(Y)`
points into X; we can then check after the fact that indeed `X: Y`
holds.

This requires a bit of "blame" detection to find where the bad
constraint came from: we are currently using a pretty dumb
algorithm. Good place for later expansion.
@nikomatsakis nikomatsakis force-pushed the nll-delay-free-region-error branch from 7ff5f1c to bdf0b89 Compare November 13, 2017 09:59
@nikomatsakis nikomatsakis merged commit bdf0b89 into nll-master Nov 13, 2017
@nikomatsakis nikomatsakis deleted the nll-delay-free-region-error branch December 2, 2017 14:33
nikomatsakis pushed a commit that referenced this pull request Sep 12, 2019
vxWorks: set DEFAULT_MIN_STACK_SIZE to 256K and use min_stack to pass initial stack size to rtpSpawn
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.

1 participant