diff --git a/first-edition/src/lifetimes.md b/first-edition/src/lifetimes.md index 042d9af97..8947deaad 100644 --- a/first-edition/src/lifetimes.md +++ b/first-edition/src/lifetimes.md @@ -53,7 +53,7 @@ Uh oh! Your reference is pointing to an invalid resource. This is called a dangling pointer or ‘use after free’, when the resource is memory. A small example of such a situation would be: -```rust,compile_fail +```rust,ignore let r; // Introduce reference: `r`. { let i = 1; // Introduce scoped value: `i`. @@ -70,7 +70,7 @@ as it can see the lifetimes of the various values in the function. When we have a function that takes arguments by reference the situation becomes more complex. Consider the following example: -```rust,compile_fail,E0106 +```rust,ignore fn skip_prefix(line: &str, prefix: &str) -> &str { // ... # line diff --git a/first-edition/src/structs.md b/first-edition/src/structs.md index 27c653aed..f11c1610d 100644 --- a/first-edition/src/structs.md +++ b/first-edition/src/structs.md @@ -255,7 +255,7 @@ rather than positions. You can define a `struct` with no members at all: -```rust,compile_fail,E0423 +```rust,ignore struct Electron {} // Use empty braces... struct Proton; // ...or just a semicolon.