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

Borrowing -> Freezing example works in 2018 edition but text says it shouldn't compile #1140

Closed
phansch opened this issue Jan 5, 2019 · 4 comments

Comments

@phansch
Copy link
Member

phansch commented Jan 5, 2019

Seen on Discord.

In the freezing example, it says that the example should not compile. And it doesn't with the 2015 edition. However, when it's executed with the 2018 edition, it compiles. Probably because of NLL? Since the 2018 edition is the default for new projects, I think the example needs to be updated.

Playground with Rust 2018
Playground with Rust 2015

@chandu0101
Copy link

also this : alias

@yous
Copy link
Contributor

yous commented Jul 10, 2019

Now it compiles with the 2015 edition, too.

@yous
Copy link
Contributor

yous commented Jul 10, 2019

Accesing _large_integer after modifying _mutable_integer gives me an error on the both 2015 and 2018 edition, so the example can be updated to do so.

@rusty-snake
Copy link
Contributor

Fixed by #1226?

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

No branches or pull requests

5 participants