{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rust/issues/32777","repository_url":"https://api.github.com/repos/rust-lang/rust","labels_url":"https://api.github.com/repos/rust-lang/rust/issues/32777/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/32777/comments","events_url":"https://api.github.com/repos/rust-lang/rust/issues/32777/events","html_url":"https://github.com/rust-lang/rust/issues/32777","id":146404525,"number":32777,"title":"Add error explanations for all error codes","user":{"login":"GuillaumeGomez","id":3050060,"avatar_url":"https://avatars.githubusercontent.com/u/3050060?v=3","gravatar_id":"","url":"https://api.github.com/users/GuillaumeGomez","html_url":"https://github.com/GuillaumeGomez","followers_url":"https://api.github.com/users/GuillaumeGomez/followers","following_url":"https://api.github.com/users/GuillaumeGomez/following{/other_user}","gists_url":"https://api.github.com/users/GuillaumeGomez/gists{/gist_id}","starred_url":"https://api.github.com/users/GuillaumeGomez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GuillaumeGomez/subscriptions","organizations_url":"https://api.github.com/users/GuillaumeGomez/orgs","repos_url":"https://api.github.com/users/GuillaumeGomez/repos","events_url":"https://api.github.com/users/GuillaumeGomez/events{/privacy}","received_events_url":"https://api.github.com/users/GuillaumeGomez/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/rust-lang/rust/labels/A-docs","name":"A-docs","color":"d7e102"},{"url":"https://api.github.com/repos/rust-lang/rust/labels/E-easy","name":"E-easy","color":"02e10c"}],"state":"open","locked":false,"assignee":{"login":"GuillaumeGomez","id":3050060,"avatar_url":"https://avatars.githubusercontent.com/u/3050060?v=3","gravatar_id":"","url":"https://api.github.com/users/GuillaumeGomez","html_url":"https://github.com/GuillaumeGomez","followers_url":"https://api.github.com/users/GuillaumeGomez/followers","following_url":"https://api.github.com/users/GuillaumeGomez/following{/other_user}","gists_url":"https://api.github.com/users/GuillaumeGomez/gists{/gist_id}","starred_url":"https://api.github.com/users/GuillaumeGomez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GuillaumeGomez/subscriptions","organizations_url":"https://api.github.com/users/GuillaumeGomez/orgs","repos_url":"https://api.github.com/users/GuillaumeGomez/repos","events_url":"https://api.github.com/users/GuillaumeGomez/events{/privacy}","received_events_url":"https://api.github.com/users/GuillaumeGomez/received_events","type":"User","site_admin":false},"milestone":null,"comments":29,"created_at":"2016-04-06T19:04:19Z","updated_at":"2016-05-14T09:37:53Z","closed_at":null,"body":"This is a reopening of #24407 issue. So I took back what was already there and updated it:\r\n\r\nThis is a metabug for `rustc --explain` error descriptions.\r\n\r\nAll the errors in need of descriptions are listed in this spreadsheet. If you'd like to help out, comment with the bunch of errors you'd like to tackle, and list yourself as assigned on the spreadsheet!\r\n\r\nChoosing a few errors in the same file is probably a good way to start.\r\n\r\n# How to add an error explanation\r\n\r\nError explanations live in:\r\n\r\n * [librustc](https://github.com/rust-lang/rust/blob/master/src/librustc/diagnostics.rs)\r\n * [librustc_trans](https://github.com/rust-lang/rust/blob/master/src/librustc_trans/diagnostics.rs)\r\n * [librustc_passes](https://github.com/rust-lang/rust/blob/master/src/librustc_passes/diagnostics.rs)\r\n * [librustc_plugin](https://github.com/rust-lang/rust/blob/master/src/librustc_plugin/diagnostics.rs)\r\n * [librustc_typeck](https://github.com/rust-lang/rust/blob/master/src/librustc_typeck/diagnostics.rs)\r\n * [librustc_privacy](https://github.com/rust-lang/rust/blob/master/src/librustc_privacy/diagnostics.rs)\r\n * [librustc_resolve](https://github.com/rust-lang/rust/blob/master/src/librustc_resolve/diagnostics.rs)\r\n * [librustc_borrowck](https://github.com/rust-lang/rust/blob/master/src/librustc_borrowck/diagnostics.rs)\r\n * [librustc_metadata](https://github.com/rust-lang/rust/blob/master/src/librustc_metadata/diagnostics.rs)\r\n * [librustc_const_eval](https://github.com/rust-lang/rust/blob/master/src/librustc_const_eval/diagnostics.rs)\r\n\r\nTo add a new explanation you have to delete the error from the register_diagnostics! invocation and add it to the register_long_diagnostics! invocation, along with the explanation. The format for the explanation is 80 characters per line, with a newline at the very start and end of the string.\r\n\r\nPlease refer to this [RFC](https://github.com/rust-lang/rfcs/pull/1567) when you'll write your error explanation (it can also helps you to start if don't know how to write it).\r\n\r\nOnce you've added an explanation you can test it out by compiling and running stage1 as follows:\r\n\r\n```shell\r\n$ make rustc-stage1\r\n$ export PATH=x86_64-unknown-linux-gnu/stage1/bin:$PATH\r\n$ export LD_LIBRARY_PATH=x86_64-unknown-linux-gnu/stage1/lib:$LD_LIBRARY_PATH\r\n$ rustc --explain EXXXX\r\n```\r\n\r\nIf you want to see how it renders as HTML you'll have to build the error index, which requires stage2:\r\n\r\n```shell\r\n$ make doc/error-index.html\r\n```\r\n\r\nYou can add -j 4 to use 4 parallel make processes:\r\n\r\n```shell\r\n$ make rustc-stage1 -j4\r\n$ make doc/error-index.html -j4\r\n```\r\n\r\nOnce you're happy with the result, submit a pull request and we'll review it.\r\n\r\n# Progress\r\n\r\n- [ ] E0090\r\n- [ ] E0103\r\n- [ ] E0104\r\n- [ ] E0167\r\n- [ ] E0174\r\n- [ ] E0182\r\n- [ ] E0183\r\n- [ ] E0196\r\n- [ ] E0203\r\n- [ ] E0208\r\n- [ ] E0212\r\n- [ ] E0224\r\n- [ ] E0226\r\n- [ ] E0227\r\n- [ ] E0228\r\n- [ ] E0230\r\n- [ ] E0231\r\n- [ ] E0238\r\n- [ ] E0242\r\n- [ ] E0245\r\n- [ ] E0254\r\n- [ ] E0278\r\n- [ ] E0279\r\n- [ ] E0280\r\n- [ ] E0284\r\n- [ ] E0298\r\n- [ ] E0299\r\n- [ ] E0311\r\n- [ ] E0312\r\n- [ ] E0313\r\n- [ ] E0314\r\n- [ ] E0315\r\n- [ ] E0316\r\n- [ ] E0320\r\n- [ ] E0328\r\n- [ ] E0374\r\n- [ ] E0375\r\n- [ ] E0376\r\n- [ ] E0377\r\n- [ ] E0385\r\n- [ ] E0388\r\n- [x] E0389\r\n- [x] E0393\r\n- [ ] E0399\r\n- [ ] E0402\r\n- [ ] E0406\r\n- [x] E0408\r\n- [x] E0409\r\n- [x] E0410\r\n- [ ] E0414\r\n- [ ] E0418\r\n- [ ] E0420\r\n- [ ] E0421\r\n- [ ] E0427\r\n- [ ] E0429\r\n- [x] E0434\r\n- [ ] E0436\r\n- [ ] E0453\r\n- [ ] E0455\r\n- [ ] E0456\r\n- [ ] E0457\r\n- [ ] E0460\r\n- [ ] E0461\r\n- [ ] E0462\r\n- [ ] E0464\r\n- [ ] E0465\r\n- [ ] E0466\r\n- [ ] E0467\r\n- [ ] E0468\r\n- [ ] E0469\r\n- [ ] E0470\r\n- [ ] E0471\r\n- [ ] E0472\r\n- [ ] E0473\r\n- [ ] E0474\r\n- [ ] E0475\r\n- [ ] E0476\r\n- [ ] E0477\r\n- [ ] E0478\r\n- [ ] E0479\r\n- [ ] E0480\r\n- [ ] E0481\r\n- [ ] E0482\r\n- [ ] E0483\r\n- [ ] E0484\r\n- [ ] E0485\r\n- [ ] E0486\r\n- [ ] E0487\r\n- [ ] E0488\r\n- [ ] E0489\r\n- [ ] E0490\r\n- [ ] E0491\r\n- [ ] E0495\r\n- [ ] E0498\r\n- [ ] E0500\r\n- [x] E0501\r\n- [ ] E0502\r\n- [ ] E0503\r\n- [ ] E0504\r\n- [ ] E0505\r\n- [x] E0506\r\n- [x] E0507\r\n- [ ] E0508\r\n- [x] E0509\r\n- [ ] E0513\r\n- [ ] E0514\r\n- [x] E0519\r\n- [x] E0520\r\n- [ ] E0521\r\n- [ ] E0523\r\n\r\ncc @steveklabnik "},"comment":{"url":"https://api.github.com/repos/rust-lang/rust/issues/comments/219210824","html_url":"https://github.com/rust-lang/rust/issues/32777#issuecomment-219210824","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/32777","id":219210824,"user":{"login":"Saser","id":582273,"avatar_url":"https://avatars.githubusercontent.com/u/582273?v=3","gravatar_id":"","url":"https://api.github.com/users/Saser","html_url":"https://github.com/Saser","followers_url":"https://api.github.com/users/Saser/followers","following_url":"https://api.github.com/users/Saser/following{/other_user}","gists_url":"https://api.github.com/users/Saser/gists{/gist_id}","starred_url":"https://api.github.com/users/Saser/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Saser/subscriptions","organizations_url":"https://api.github.com/users/Saser/orgs","repos_url":"https://api.github.com/users/Saser/repos","events_url":"https://api.github.com/users/Saser/events{/privacy}","received_events_url":"https://api.github.com/users/Saser/received_events","type":"User","site_admin":false},"created_at":"2016-05-14T09:37:53Z","updated_at":"2016-05-14T09:37:53Z","body":"Is the spreadsheet from the old issue still relevant? In that case, you might want to add a link to it from this issue as well. :blush: "}}