We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
The question states:
Replacing the implementation of deref with self.as_ref() results in a stack overflow when running an unoptimized version. Why? (Hint: deref coercion)
But actually self.as_ref() does not cause stack overflow: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=9ce74e7edda0542dbf20c04f521b2879.
self.as_ref()
Not sure if I misunderstand something here.
PS: I cannot give a link to above quote directly because the book's website is broken: https://teach-rs.trifectatech.org/full .
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The question states:
But actually
self.as_ref()
does not cause stack overflow: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=9ce74e7edda0542dbf20c04f521b2879.Not sure if I misunderstand something here.
PS: I cannot give a link to above quote directly because the book's website is broken: https://teach-rs.trifectatech.org/full .
The text was updated successfully, but these errors were encountered: