{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rust/issues/25489","labels_url":"https://api.github.com/repos/rust-lang/rust/issues/25489/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/25489/comments","events_url":"https://api.github.com/repos/rust-lang/rust/issues/25489/events","html_url":"https://github.com/rust-lang/rust/issues/25489","id":77031097,"number":25489,"title":"Dining philosophers tutorial no longer works.","user":{"login":"Aaronepower","id":4464295,"avatar_url":"https://avatars.githubusercontent.com/u/4464295?v=3","gravatar_id":"","url":"https://api.github.com/users/Aaronepower","html_url":"https://github.com/Aaronepower","followers_url":"https://api.github.com/users/Aaronepower/followers","following_url":"https://api.github.com/users/Aaronepower/following{/other_user}","gists_url":"https://api.github.com/users/Aaronepower/gists{/gist_id}","starred_url":"https://api.github.com/users/Aaronepower/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Aaronepower/subscriptions","organizations_url":"https://api.github.com/users/Aaronepower/orgs","repos_url":"https://api.github.com/users/Aaronepower/repos","events_url":"https://api.github.com/users/Aaronepower/events{/privacy}","received_events_url":"https://api.github.com/users/Aaronepower/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/rust-lang/rust/labels/A-book","name":"A-book","color":"d7e102"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-05-16T12:42:15Z","updated_at":"2015-05-16T16:01:19Z","closed_at":null,"body":"```rust\r\nuse std::thread;\r\n\r\nstruct Philosopher {\r\n    name: String,\r\n}   \r\n\r\nimpl Philosopher { \r\n    fn new(name: &str) -> Philosopher {\r\n        Philosopher {\r\n            name: name.to_string(),\r\n        }\r\n    }\r\n\r\n    fn eat(&self) {\r\n        println!(\"{} is eating.\", self.name);\r\n\r\n        thread::sleep_ms(1000);\r\n\r\n        println!(\"{} is done eating.\", self.name);\r\n    }\r\n}\r\n\r\nfn main() {\r\n    let philosophers = vec![\r\n        Philosopher::new(\"Baruch Spinoza\"),\r\n        Philosopher::new(\"Gilles Deleuze\"),\r\n        Philosopher::new(\"Karl Marx\"),\r\n        Philosopher::new(\"Friedrich Nietzsche\"),\r\n        Philosopher::new(\"Michel Foucault\"),\r\n    ];\r\n\r\n    let handles: Vec<_> = philosophers.into_iter().map(|p| {\r\n        thread::spawn(move || {\r\n            p.eat();\r\n        })\r\n    }).collect();\r\n\r\n    for h in handles {\r\n        h.join().unwrap();\r\n    }\r\n}\r\n```\r\nThe code snippet now generates the following error.\r\n\r\n```\r\nCompiling dining_philosophers v0.0.1 (file:///G:/Rust/dining_philosophers)\r\n     Running `rustc src\\main.rs --crate-name dining_philosophers --crate-type bin -g --out-dir G:\\Rust\\dining_philosophers\\target\\debug --emit=dep-info,link -L dependency=G:\\Rust\\dining_philosophers\\target\\debug -L dependency=G:\\Rust\\dining_philosophers\\target\\debug\\deps`\r\nsrc\\main.rs:39:18: 39:26 error: type `core::result::Result<(), Box<core::any::Any + Send>>` does not implement any method in scope named `unwrap`\r\nsrc\\main.rs:39         h.join().unwrap();\r\n                                ^~~~~~~~\r\nerror: aborting due to previous error\r\nCould not compile `dining_philosophers`.\r\n\r\nCaused by:\r\n  Process didn't exit successfully: `rustc src\\main.rs --crate-name dining_philosophers --crate-type bin -g --out-dir G:\\Rust\\dining_philosophers\\target\\debug --emit=dep-info,link -L dependency=G:\\Rust\\dining_philosophers\\target\\debug -L dependency=G:\\Rust\\dining_philosophers\\target\\debug\\deps` (exit code: 101)\r\n\r\n```"},"comment":{"url":"https://api.github.com/repos/rust-lang/rust/issues/comments/102643697","html_url":"https://github.com/rust-lang/rust/issues/25489#issuecomment-102643697","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/25489","id":102643697,"user":{"login":"Stebalien","id":310393,"avatar_url":"https://avatars.githubusercontent.com/u/310393?v=3","gravatar_id":"","url":"https://api.github.com/users/Stebalien","html_url":"https://github.com/Stebalien","followers_url":"https://api.github.com/users/Stebalien/followers","following_url":"https://api.github.com/users/Stebalien/following{/other_user}","gists_url":"https://api.github.com/users/Stebalien/gists{/gist_id}","starred_url":"https://api.github.com/users/Stebalien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Stebalien/subscriptions","organizations_url":"https://api.github.com/users/Stebalien/orgs","repos_url":"https://api.github.com/users/Stebalien/repos","events_url":"https://api.github.com/users/Stebalien/events{/privacy}","received_events_url":"https://api.github.com/users/Stebalien/received_events","type":"User","site_admin":false},"created_at":"2015-05-16T16:01:19Z","updated_at":"2015-05-16T16:01:19Z","body":"What's your rust version?"}}