Skip to content

Clear explanation of the rules enforced by the alias checker needed #1823

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

Closed
nikomatsakis opened this issue Feb 12, 2012 · 4 comments
Closed
Labels
C-enhancement Category: An issue proposing an enhancement or a PR with one.

Comments

@nikomatsakis
Copy link
Contributor

As far as I could tell, the precise rules enforced by the alias checker are not documented. I may well be wrong about this, but I searched the tutorial and reference manual for the word "alias" without success. This makes it hard to explain to people why a particular expression is or is not considered immutably rooted and so forth. We ought to have a chapter in the reference manual we can point to (perhaps even as part of the compiler error message). I guess @marijnh is by far the best qualified to write such a thing (both in the sense of being capable of a clear explanation and in the sense of being the one who understands that code the best). Perhaps we ought to wait until we decide what we are doing about regions, though. Anyway, if such a thing already exists, please close this bug and let me know where it is.

@marijnh
Copy link
Contributor

marijnh commented Feb 12, 2012

It's not called 'alias' anymore, but safe reference. There's a bit about it in the tutorial, but nothing exhaustive.

@nikomatsakis
Copy link
Contributor Author

Still, good to know. At least I can point people to http://doc.rust-lang.org/doc/tutorial.html#safe-references

@graydon
Copy link
Contributor

graydon commented Apr 11, 2012

Marking as likely-obsolete / should-close, since I think this component is slated for removal when we move to region-checking for this sort of safety-enforcement. Agreed?

@nikomatsakis
Copy link
Contributor Author

Agreed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category: An issue proposing an enhancement or a PR with one.
Projects
None yet
Development

No branches or pull requests

3 participants