error[E0599]: no method named `rbrbrb` found for enum `std::result::Result<i32, std::num::ParseIntError>` in the current scope
error[E0599]: no method named `rbrbrb` found for enum `std::result::Result<i32, std::num::ParseIntError>` in the current scope
--> src\main.rs:3:13
--> src\main.rs:3:13
|
|
@ -3147,7 +3146,7 @@ fn main() {
It will display:
It will display:
```
```text
thread 'main' panicked at 'assertion failed: `(left != right)`
thread 'main' panicked at 'assertion failed: `(left != right)`
left: `"Mithridates"`,
left: `"Mithridates"`,
right: `"Mithridates"`: Mithridates must not equal Mithridates', src\main.rs:4:5
right: `"Mithridates"`: Mithridates must not equal Mithridates', src\main.rs:4:5
@ -3288,7 +3287,7 @@ fn run(&self) -> i32 {
Rust will say:
Rust will say:
```
```text
= note: expected fn pointer `fn(&Animal)`
= note: expected fn pointer `fn(&Animal)`
found fn pointer `fn(&Animal) -> i32`
found fn pointer `fn(&Animal) -> i32`
```
```
@ -3446,7 +3445,7 @@ Success! Now when we use `{}` to print, we get `Reggie Mantle is a cat who is 4
*From* is a very convenient trait to use, and you know this because you have seen it so much already. With *From* you can make a `String` from a `&str`, but you can make many types from many other types. For example, Vec uses *From* for the following:
*From* is a very convenient trait to use, and you know this because you have seen it so much already. With *From* you can make a `String` from a `&str`, but you can make many types from many other types. For example, Vec uses *From* for the following:
error[E0412]: cannot find type `WorldsBestType` in this scope
error[E0412]: cannot find type `WorldsBestType` in this scope
--> src\main.rs:32:29
--> src\main.rs:32:29
|
|
@ -5410,7 +5409,7 @@ fn main() {
Usually about four threads will print before `main` ends, but it is always different. Also, sometimes the threads will panic:
Usually about four threads will print before `main` ends, but it is always different. Also, sometimes the threads will panic:
```
```text
thread 'thread 'I am printing something
thread 'thread 'I am printing something
thread '<unnamed><unnamed>thread '' panicked at '<unnamed>I am printing something
thread '<unnamed><unnamed>thread '' panicked at '<unnamed>I am printing something
' panicked at 'thread '<unnamed>cannot access stdout during shutdown' panicked at '<unnamed>thread 'cannot access stdout during
' panicked at 'thread '<unnamed>cannot access stdout during shutdown' panicked at '<unnamed>thread 'cannot access stdout during
@ -5499,7 +5498,7 @@ fn main() {
This prints:
This prints:
```
```text
I will go into the closure now
I will go into the closure now
I will go into the closure now now
I will go into the closure now now
```
```
@ -5539,7 +5538,7 @@ fn main() {
The compiler says that this won't work.
The compiler says that this won't work.
```
```text
error[E0373]: closure may outlive the current function, but it borrows `my_string`, which is owned by the current function
error[E0373]: closure may outlive the current function, but it borrows `my_string`, which is owned by the current function
--> src\main.rs:28:37
--> src\main.rs:28:37
|
|
@ -5734,7 +5733,7 @@ fn main() {
The program prints:
The program prints:
```
```text
Value is: Mutex { data: 20 }
Value is: Mutex { data: 20 }
Exiting the program
Exiting the program
```
```
@ -5841,7 +5840,7 @@ fn main() {
The compiler says:
The compiler says:
```
```text
error[E0282]: type annotations needed for `(std::sync::mpsc::Sender<T>, std::sync::mpsc::Receiver<T>)`
error[E0282]: type annotations needed for `(std::sync::mpsc::Sender<T>, std::sync::mpsc::Receiver<T>)`
--> src\main.rs:30:30
--> src\main.rs:30:30
|
|
@ -5939,7 +5938,7 @@ fn main() {
This prints:
This prints:
```
```text
"Send a &str this time"
"Send a &str this time"
"And here is another &str"
"And here is another &str"
```
```
@ -6141,7 +6140,7 @@ struct List {
This simple `List` has one item, that may be `Some<List>` (another list), or `None`. Because you can choose `None`, it will not be recursive forever. But the compiler still doesn't know the size:
This simple `List` has one item, that may be `Some<List>` (another list), or `None`. Because you can choose `None`, it will not be recursive forever. But the compiler still doesn't know the size:
```
```text
error[E0072]: recursive type `List` has infinite size
error[E0072]: recursive type `List` has infinite size