1
0
mirror of https://github.com/google/comprehensive-rust.git synced 2025-04-26 09:12:58 +02:00

Fix Godbolt typo (#1014)

This commit is contained in:
Martin Geisler 2023-07-22 00:01:10 +02:00 committed by GitHub
parent 6e367132ad
commit 03bc5be016
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -25,7 +25,7 @@ fn main() {
<details>
Notes on stack returns:
* Demonstrate that the return from `add` is cheap because the compiler can eliminate the copy operation. Change the above code to print stack addresses and run it on the [Playground] or look at the assembly in [Godbold](https://rust.godbolt.org/). In the "DEBUG" optimization level, the addresses should change, while they stay the same when changing to the "RELEASE" setting:
* Demonstrate that the return from `add` is cheap because the compiler can eliminate the copy operation. Change the above code to print stack addresses and run it on the [Playground] or look at the assembly in [Godbolt](https://rust.godbolt.org/). In the "DEBUG" optimization level, the addresses should change, while they stay the same when changing to the "RELEASE" setting:
```rust,editable
#[derive(Debug)]
@ -50,4 +50,4 @@ Notes on stack returns:
</details>
[Playground]: https://play.rust-lang.org/
[Playground]: https://play.rust-lang.org/