{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rfcs/issues/1868","repository_url":"https://api.github.com/repos/rust-lang/rfcs","labels_url":"https://api.github.com/repos/rust-lang/rfcs/issues/1868/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rfcs/issues/1868/comments","events_url":"https://api.github.com/repos/rust-lang/rfcs/issues/1868/events","html_url":"https://github.com/rust-lang/rfcs/pull/1868","id":202619598,"number":1868,"title":"RFC: A portability lint","user":{"login":"aturon","id":709807,"avatar_url":"https://avatars1.githubusercontent.com/u/709807?v=3","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":211667886,"url":"https://api.github.com/repos/rust-lang/rfcs/labels/T-lang","name":"T-lang","color":"bfd4f2","default":false},{"id":211667901,"url":"https://api.github.com/repos/rust-lang/rfcs/labels/T-libs","name":"T-libs","color":"bfd4f2","default":false}],"state":"open","locked":false,"assignee":{"login":"aturon","id":709807,"avatar_url":"https://avatars1.githubusercontent.com/u/709807?v=3","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},"assignees":[{"login":"aturon","id":709807,"avatar_url":"https://avatars1.githubusercontent.com/u/709807?v=3","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}],"milestone":null,"comments":30,"created_at":"2017-01-23T18:56:08Z","updated_at":"2017-03-01T09:00:43Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/rust-lang/rfcs/pulls/1868","html_url":"https://github.com/rust-lang/rfcs/pull/1868","diff_url":"https://github.com/rust-lang/rfcs/pull/1868.diff","patch_url":"https://github.com/rust-lang/rfcs/pull/1868.patch"},"body":"There has long been a desire to expand the number of platform- and architecture-specific APIs in the standard library, and to offer subsets of the standard library for working in constrained environments. At the same time, we want to retain the property that Rust code is portable by default.\r\n\r\nThis RFC proposes a new *portability lint*, which threads the needle between these two desires. The lint piggybacks on the existing `cfg` system, so that using APIs involving `cfg` will generate a warning unless there is explicit acknowledgment of the portability implications.\r\n\r\nThe lint is intended to make the existing `std::os` module obsolete, to allow expansion (and subsetting) of the standard library, and to provide deeper checking for portability across the ecosystem.\r\n\r\n[Rendered](https://github.com/aturon/rfcs/blob/scenarios/text/0000-portability-lint.md)"},"comment":{"url":"https://api.github.com/repos/rust-lang/rfcs/issues/comments/283282846","html_url":"https://github.com/rust-lang/rfcs/pull/1868#issuecomment-283282846","issue_url":"https://api.github.com/repos/rust-lang/rfcs/issues/1868","id":283282846,"user":{"login":"Ixrec","id":5285357,"avatar_url":"https://avatars1.githubusercontent.com/u/5285357?v=3","gravatar_id":"","url":"https://api.github.com/users/Ixrec","html_url":"https://github.com/Ixrec","followers_url":"https://api.github.com/users/Ixrec/followers","following_url":"https://api.github.com/users/Ixrec/following{/other_user}","gists_url":"https://api.github.com/users/Ixrec/gists{/gist_id}","starred_url":"https://api.github.com/users/Ixrec/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ixrec/subscriptions","organizations_url":"https://api.github.com/users/Ixrec/orgs","repos_url":"https://api.github.com/users/Ixrec/repos","events_url":"https://api.github.com/users/Ixrec/events{/privacy}","received_events_url":"https://api.github.com/users/Ixrec/received_events","type":"User","site_admin":false},"created_at":"2017-03-01T09:00:43Z","updated_at":"2017-03-01T09:00:43Z","body":"I'm also fine with only generating a warning for the current target _for now_. This is a best-effort lint for a reason. I would like it to generate warnings for both of the incorrect targets, but that's a reasonable thing to put off until a second or third iteration on the implementation.\r\n\r\nThe really important case imo is that an as_raw_fd() or as_raw_handle() call with no cfg on it at all gets a warning no matter what you're building on."}}
{"actor":{"display_login":"Ixrec"}}