Skip to content

Commit

Permalink
Delete trailing whitespace in dining philosophers example
Browse files Browse the repository at this point in the history
  • Loading branch information
lambda committed May 20, 2015
1 parent d73f3ff commit b032c40
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions src/doc/trpl/dining-philosophers.md
Expand Up @@ -144,15 +144,15 @@ look at `main()` again:
# struct Philosopher {
# name: String,
# }
#
#
# impl Philosopher {
# fn new(name: &str) -> Philosopher {
# Philosopher {
# name: name.to_string(),
# }
# }
# }
#
#
fn main() {
let p1 = Philosopher::new("Plato");
let p2 = Philosopher::new("Hypatia");
Expand Down Expand Up @@ -190,15 +190,15 @@ a method, and then loop through all the philosophers, calling it:
```rust
struct Philosopher {
name: String,
}
}

impl Philosopher {
impl Philosopher {
fn new(name: &str) -> Philosopher {
Philosopher {
name: name.to_string(),
}
}

fn eat(&self) {
println!("{} is done eating.", self.name);
}
Expand Down Expand Up @@ -260,15 +260,15 @@ use std::thread;

struct Philosopher {
name: String,
}
}

impl Philosopher {
impl Philosopher {
fn new(name: &str) -> Philosopher {
Philosopher {
name: name.to_string(),
}
}

fn eat(&self) {
println!("{} is eating.", self.name);

Expand Down Expand Up @@ -341,9 +341,9 @@ use std::thread;

struct Philosopher {
name: String,
}
}

impl Philosopher {
impl Philosopher {
fn new(name: &str) -> Philosopher {
Philosopher {
name: name.to_string(),
Expand Down Expand Up @@ -394,7 +394,7 @@ let handles: Vec<_> = philosophers.into_iter().map(|p| {
While this is only five lines, they’re a dense five. Let’s break it down.

```rust,ignore
let handles: Vec<_> =
let handles: Vec<_> =
```

We introduce a new binding, called `handles`. We’ve given it this name because
Expand Down

0 comments on commit b032c40

Please sign in to comment.