{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rust/issues/34511","repository_url":"https://api.github.com/repos/rust-lang/rust","labels_url":"https://api.github.com/repos/rust-lang/rust/issues/34511/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/34511/comments","events_url":"https://api.github.com/repos/rust-lang/rust/issues/34511/events","html_url":"https://github.com/rust-lang/rust/issues/34511","id":162545419,"node_id":"MDU6SXNzdWUxNjI1NDU0MTk=","number":34511,"title":"Tracking issue for `impl Trait` (RFC 1522, RFC 1951, RFC 2071)","user":{"login":"aturon","id":709807,"node_id":"MDQ6VXNlcjcwOTgwNw==","avatar_url":"https://avatars2.githubusercontent.com/u/709807?v=4","gravatar_id":"","url":"https://api.github.com/users/aturon","html_url":"https://github.com/aturon","followers_url":"https://api.github.com/users/aturon/followers","following_url":"https://api.github.com/users/aturon/following{/other_user}","gists_url":"https://api.github.com/users/aturon/gists{/gist_id}","starred_url":"https://api.github.com/users/aturon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aturon/subscriptions","organizations_url":"https://api.github.com/users/aturon/orgs","repos_url":"https://api.github.com/users/aturon/repos","events_url":"https://api.github.com/users/aturon/events{/privacy}","received_events_url":"https://api.github.com/users/aturon/received_events","type":"User","site_admin":false},"labels":[{"id":433146169,"node_id":"MDU6TGFiZWw0MzMxNDYxNjk=","url":"https://api.github.com/repos/rust-lang/rust/labels/B-RFC-implemented","name":"B-RFC-implemented","color":"d304cb","default":false},{"id":246778137,"node_id":"MDU6TGFiZWwyNDY3NzgxMzc=","url":"https://api.github.com/repos/rust-lang/rust/labels/B-unstable","name":"B-unstable","color":"d304cb","default":false},{"id":650846969,"node_id":"MDU6TGFiZWw2NTA4NDY5Njk=","url":"https://api.github.com/repos/rust-lang/rust/labels/C-tracking-issue","name":"C-tracking-issue","color":"f5f1fd","default":false},{"id":211668019,"node_id":"MDU6TGFiZWwyMTE2NjgwMTk=","url":"https://api.github.com/repos/rust-lang/rust/labels/T-lang","name":"T-lang","color":"bfd4f2","default":false},{"id":919710011,"node_id":"MDU6TGFiZWw5MTk3MTAwMTE=","url":"https://api.github.com/repos/rust-lang/rust/labels/disposition-merge","name":"disposition-merge","color":"008800","default":false},{"id":923282386,"node_id":"MDU6TGFiZWw5MjMyODIzODY=","url":"https://api.github.com/repos/rust-lang/rust/labels/finished-final-comment-period","name":"finished-final-comment-period","color":"f9e189","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":344,"created_at":"2016-06-27T20:51:36Z","updated_at":"2018-07-04T16:57:07Z","closed_at":null,"author_association":"MEMBER","body":"### Implementation status\r\n\r\nThe basic feature as specified in [RFC 1522](https://github.com/rust-lang/rfcs/pull/1522) is implemented, however there have been revisions that are still in need of work:\r\n\r\n- [x] [impl Trait in argument position](https://github.com/rust-lang/rust/issues/44721)\r\n    - [x] extend to cover traits\r\n    - [ ] support elision https://github.com/rust-lang/rust/issues/49287\r\n- [x] impl Trait in return position is basically implemented, but:\r\n    - [x] [filter lifetimes](https://github.com/rust-lang/rust/issues/44725)\r\n    - [x] code accepts types with out-of-scope lifetimes https://github.com/rust-lang/rust/issues/46541\r\n    - [x] ICEs when interacting with elision https://github.com/rust-lang/rust/issues/43396\r\n    - [x] ICE combining universal and existential https://github.com/rust-lang/rust/issues/46685\r\n    - [x] ICE with nested lifetimes https://github.com/rust-lang/rust/issues/46464\r\n    - [x] Infinitely recursive types not detected https://github.com/rust-lang/rust/issues/38064\r\n        - [ ] Better error message for infinitely recursive types https://github.com/rust-lang/rust/issues/47659\r\n    - [x] do not accept [nested impl trait described here](https://github.com/rust-lang/rust/issues/34511#issuecomment-359950524) (fixed in #48072)\r\n- [ ] deferred: `let x: impl Trait`\r\n- [ ] deferred: `static` and `const T: impl Trait`\r\n- [ ] `abstract type` \r\n    - [x] [preliminary refactoring possibility](https://github.com/rust-lang/rust/issues/44727)\r\n    - [ ] in modules\r\n    - [ ] in traits\r\n\r\n### RFCs\r\n\r\nThere have been a number of RFCs regarding impl trait, all of which are tracked by this central tracking issue.\r\n\r\n- https://github.com/rust-lang/rfcs/pull/1522\r\n    - the original, which covered only impl Trait in return position for inherent functions\r\n- https://github.com/rust-lang/rfcs/pull/1951\r\n    - settling on a particular syntax design, resolving questions around the some/any proposal and others.\r\n    - resolving questions around which type and lifetime parameters are considered in scope for an impl Trait.\r\n    - adding impl Trait to argument position.\r\n- https://github.com/rust-lang/rfcs/pull/2071\r\n    - named `abstract type` in modules and impls\r\n      - [ ] Finalize syntax\r\n      - [ ] Update RFC https://github.com/rust-lang/rfcs/pull/2289 to match that syntax if that RFC gets merged.\r\n    - use of impl trait in `let`, `const`, and `static` positions\r\n- https://github.com/rust-lang/rfcs/pull/2250\r\n    - Finalizing the syntax of `impl Trait` and `dyn Trait` with multiple bounds\r\n\r\n### Unresolved questions\r\n\r\nThe implementation has raised a number of interesting questions as well:\r\n\r\n- [x] What is the precedence of the `impl` keyword when parsing types? Discussion: [1](https://github.com/rust-lang/rust/pull/35091#discussion_r73736079)\r\n    - e.g., how to associate `Send` for `where F: Fn() -> impl Foo + Send`?\r\n    - Resolved by https://github.com/rust-lang/rfcs/pull/2250.\r\n    - [x] Implemented (?) in https://github.com/rust-lang/rust/pull/45294\r\n- [ ]  Should we allow `impl Trait` after `->` in `fn` types or parentheses sugar? #45994 \r\n- [ ] Do we have to impose a DAG across all functions to allow for auto-safe leakage, or can we use some kind of deferral. Discussion: [1](https://github.com/rust-lang/rust/pull/35091#discussion_r73738398)\r\n    - Present semantics: DAG.\r\n- [x] How should we integrate impl trait into regionck? Discussion: [1](https://github.com/rust-lang/rust/pull/35091#discussion_r73734987), [2](https://github.com/rust-lang/rust/issues/34511#issuecomment-237289787)\r\n    - Resolved in https://github.com/rust-lang/rust/pull/45701\r\n- [ ] Should we permit specifying types if some parameters are implicit and some are explicit? e.g., `fn foo<T>(x: impl Iterator<Item = T>>)`?\r\n    - Current behavior: An error to specify types\r\n    - Other alternatives: [treat `impl Trait` as arguments in the list, permitting migration](https://github.com/rust-lang/rust/issues/44721#issuecomment-330921814)\r\n- [ ] [Some concerns about nested impl Trait usage](https://github.com/rust-lang/rust/issues/34511#issuecomment-350715858)"},"comment":{"url":"https://api.github.com/repos/rust-lang/rust/issues/comments/402526676","html_url":"https://github.com/rust-lang/rust/issues/34511#issuecomment-402526676","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/34511","id":402526676,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMjUyNjY3Ng==","user":{"login":"Centril","id":855702,"node_id":"MDQ6VXNlcjg1NTcwMg==","avatar_url":"https://avatars2.githubusercontent.com/u/855702?v=4","gravatar_id":"","url":"https://api.github.com/users/Centril","html_url":"https://github.com/Centril","followers_url":"https://api.github.com/users/Centril/followers","following_url":"https://api.github.com/users/Centril/following{/other_user}","gists_url":"https://api.github.com/users/Centril/gists{/gist_id}","starred_url":"https://api.github.com/users/Centril/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Centril/subscriptions","organizations_url":"https://api.github.com/users/Centril/orgs","repos_url":"https://api.github.com/users/Centril/repos","events_url":"https://api.github.com/users/Centril/events{/privacy}","received_events_url":"https://api.github.com/users/Centril/received_events","type":"User","site_admin":false},"created_at":"2018-07-04T16:57:07Z","updated_at":"2018-07-04T16:57:07Z","author_association":"CONTRIBUTOR","body":"@iopq In addition to @varkor's note about recent changes, I'd also like to add that for other search engines, it is always possible that official documentation and such explicitly use the literal word \"underscore\" in conjunction with `type` such that it becomes searchable."}}
{"actor":{"display_login":"Centril"}}