{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rust/issues/22696","labels_url":"https://api.github.com/repos/rust-lang/rust/issues/22696/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/22696/comments","events_url":"https://api.github.com/repos/rust-lang/rust/issues/22696/events","html_url":"https://github.com/rust-lang/rust/pull/22696","id":58529961,"number":22696,"title":"Use boxed functions instead of transmute in the standard libraries","user":{"login":"stepancheg","id":28969,"avatar_url":"https://avatars.githubusercontent.com/u/28969?v=3","gravatar_id":"","url":"https://api.github.com/users/stepancheg","html_url":"https://github.com/stepancheg","followers_url":"https://api.github.com/users/stepancheg/followers","following_url":"https://api.github.com/users/stepancheg/following{/other_user}","gists_url":"https://api.github.com/users/stepancheg/gists{/gist_id}","starred_url":"https://api.github.com/users/stepancheg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stepancheg/subscriptions","organizations_url":"https://api.github.com/users/stepancheg/orgs","repos_url":"https://api.github.com/users/stepancheg/repos","events_url":"https://api.github.com/users/stepancheg/events{/privacy}","received_events_url":"https://api.github.com/users/stepancheg/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"alexcrichton","id":64996,"avatar_url":"https://avatars.githubusercontent.com/u/64996?v=3","gravatar_id":"","url":"https://api.github.com/users/alexcrichton","html_url":"https://github.com/alexcrichton","followers_url":"https://api.github.com/users/alexcrichton/followers","following_url":"https://api.github.com/users/alexcrichton/following{/other_user}","gists_url":"https://api.github.com/users/alexcrichton/gists{/gist_id}","starred_url":"https://api.github.com/users/alexcrichton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexcrichton/subscriptions","organizations_url":"https://api.github.com/users/alexcrichton/orgs","repos_url":"https://api.github.com/users/alexcrichton/repos","events_url":"https://api.github.com/users/alexcrichton/events{/privacy}","received_events_url":"https://api.github.com/users/alexcrichton/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2015-02-23T00:06:26Z","updated_at":"2015-02-23T14:05:50Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/rust-lang/rust/pulls/22696","html_url":"https://github.com/rust-lang/rust/pull/22696","diff_url":"https://github.com/rust-lang/rust/pull/22696.diff","patch_url":"https://github.com/rust-lang/rust/pull/22696.patch"},"body":"e. g.\r\n\r\n```\r\nlet b: Box<Foo> = Box::from_raw(p);\r\n```\r\n\r\ninstead of\r\n\r\n```\r\nlet b: Box<Foo> = mem::transmute(p);\r\n```\r\n\r\nPatch also changes closure release code in `src/libstd/sys/unix/thread.rs`\r\nwhen `pthread_create` failed. Raw pointer was transmuted to box of\r\n`FnOnce()` instead of `Thunk`. This code was probably never executed,\r\nbecause `pthread_create` rarely fails.\r\n\r\n(And there are two more patches in PR: fix typo in doc and mark `from_raw` and `into_raw` functions inline.)"},"comment":{"url":"https://api.github.com/repos/rust-lang/rust/issues/comments/75545667","html_url":"https://github.com/rust-lang/rust/pull/22696#issuecomment-75545667","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/22696","id":75545667,"user":{"login":"Manishearth","id":1617736,"avatar_url":"https://avatars.githubusercontent.com/u/1617736?v=3","gravatar_id":"","url":"https://api.github.com/users/Manishearth","html_url":"https://github.com/Manishearth","followers_url":"https://api.github.com/users/Manishearth/followers","following_url":"https://api.github.com/users/Manishearth/following{/other_user}","gists_url":"https://api.github.com/users/Manishearth/gists{/gist_id}","starred_url":"https://api.github.com/users/Manishearth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Manishearth/subscriptions","organizations_url":"https://api.github.com/users/Manishearth/orgs","repos_url":"https://api.github.com/users/Manishearth/repos","events_url":"https://api.github.com/users/Manishearth/events{/privacy}","received_events_url":"https://api.github.com/users/Manishearth/received_events","type":"User","site_admin":false},"created_at":"2015-02-23T14:05:50Z","updated_at":"2015-02-23T14:05:50Z","body":"Needs https://github.com/Manishearth/rust/commit/f1447f1da36cb3df19af088c7147141c71935838 to work on master.\r\n\r\n\r\nYou're part of the rollup, so you shouldn't have to worry about this though."}}