{"action":"created","comment":{"url":"https://api.github.com/repos/rust-lang/rust/pulls/comments/188508019","pull_request_review_id":120498705,"id":188508019,"diff_hunk":"@@ -78,6 +78,9 @@ pub fn check_intrinsic_type<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>,\n                                       it: &hir::ForeignItem) {\n     let param = |n| tcx.mk_param(n, Symbol::intern(&format!(\"P{}\", n)).as_interned_str());\n     let name = it.name.as_str();\n+    let va_list_ty = tcx.lang_items().va_list().map(|did| {\n+        tcx.type_of(did)\n+    });","path":"src/librustc_typeck/check/intrinsic.rs","position":6,"original_position":6,"commit_id":"fbf2ad3973ffa5270cd0aa8f08c37045192ed6ad","original_commit_id":"fbf2ad3973ffa5270cd0aa8f08c37045192ed6ad","user":{"login":"eddyb","id":77424,"avatar_url":"https://avatars2.githubusercontent.com/u/77424?v=4","gravatar_id":"","url":"https://api.github.com/users/eddyb","html_url":"https://github.com/eddyb","followers_url":"https://api.github.com/users/eddyb/followers","following_url":"https://api.github.com/users/eddyb/following{/other_user}","gists_url":"https://api.github.com/users/eddyb/gists{/gist_id}","starred_url":"https://api.github.com/users/eddyb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eddyb/subscriptions","organizations_url":"https://api.github.com/users/eddyb/orgs","repos_url":"https://api.github.com/users/eddyb/repos","events_url":"https://api.github.com/users/eddyb/events{/privacy}","received_events_url":"https://api.github.com/users/eddyb/received_events","type":"User","site_admin":false},"body":"Okay, I took a look at the rest of this file, and I think the fix for the lifetime problem is:\r\nhttps://github.com/rust-lang/rust/blob/3c31e17ddc8914365145683e6d56fa0229a01a8e/src/librustc_typeck/check/intrinsic.rs#L122-L123\r\nSpecifically, the `mk_region` call, which could be used like so:\r\n```rust\r\n        tcx.type_of(did).subst(tcx, &[\r\n            tcx.mk_region(ty::ReLateBound(ty::DebruijnIndex::new(1), ty::BrAnon(0))).into()\r\n        ])\r\n```","created_at":"2018-05-16T05:41:58Z","updated_at":"2018-05-16T05:41:58Z","html_url":"https://github.com/rust-lang/rust/pull/49878#discussion_r188508019","pull_request_url":"https://api.github.com/repos/rust-lang/rust/pulls/49878","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/comments/188508019"},"html":{"href":"https://github.com/rust-lang/rust/pull/49878#discussion_r188508019"},"pull_request":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/49878"}}},"pull_request":{"url":"https://api.github.com/repos/rust-lang/rust/pulls/49878","id":180908435,"html_url":"https://github.com/rust-lang/rust/pull/49878","diff_url":"https://github.com/rust-lang/rust/pull/49878.diff","patch_url":"https://github.com/rust-lang/rust/pull/49878.patch","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/49878","number":49878,"state":"open","locked":false,"title":"libcore: Add VaList and variadic arg handling intrinsics","user":{"login":"dlrobertson","id":7504153,"avatar_url":"https://avatars1.githubusercontent.com/u/7504153?v=4","gravatar_id":"","url":"https://api.github.com/users/dlrobertson","html_url":"https://github.com/dlrobertson","followers_url":"https://api.github.com/users/dlrobertson/followers","following_url":"https://api.github.com/users/dlrobertson/following{/other_user}","gists_url":"https://api.github.com/users/dlrobertson/gists{/gist_id}","starred_url":"https://api.github.com/users/dlrobertson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlrobertson/subscriptions","organizations_url":"https://api.github.com/users/dlrobertson/orgs","repos_url":"https://api.github.com/users/dlrobertson/repos","events_url":"https://api.github.com/users/dlrobertson/events{/privacy}","received_events_url":"https://api.github.com/users/dlrobertson/received_events","type":"User","site_admin":false},"body":"## Summary\r\n\r\n - Add intrinsics for `va_start`, `va_end`, `va_copy`, and `va_arg`.\r\n - Add `core::va_list::VaList` to `libcore`.\r\n\r\nPart 1 of (at least) 3 for #44930 \r\n\r\nComments and critiques are very much welcomed 😄","created_at":"2018-04-11T13:43:48Z","updated_at":"2018-05-16T05:41:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":"446d9ee52c88173a67dbb1935a99ecedb41f7930","assignee":{"login":"eddyb","id":77424,"avatar_url":"https://avatars2.githubusercontent.com/u/77424?v=4","gravatar_id":"","url":"https://api.github.com/users/eddyb","html_url":"https://github.com/eddyb","followers_url":"https://api.github.com/users/eddyb/followers","following_url":"https://api.github.com/users/eddyb/following{/other_user}","gists_url":"https://api.github.com/users/eddyb/gists{/gist_id}","starred_url":"https://api.github.com/users/eddyb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eddyb/subscriptions","organizations_url":"https://api.github.com/users/eddyb/orgs","repos_url":"https://api.github.com/users/eddyb/repos","events_url":"https://api.github.com/users/eddyb/events{/privacy}","received_events_url":"https://api.github.com/users/eddyb/received_events","type":"User","site_admin":false},"assignees":[{"login":"eddyb","id":77424,"avatar_url":"https://avatars2.githubusercontent.com/u/77424?v=4","gravatar_id":"","url":"https://api.github.com/users/eddyb","html_url":"https://github.com/eddyb","followers_url":"https://api.github.com/users/eddyb/followers","following_url":"https://api.github.com/users/eddyb/following{/other_user}","gists_url":"https://api.github.com/users/eddyb/gists{/gist_id}","starred_url":"https://api.github.com/users/eddyb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eddyb/subscriptions","organizations_url":"https://api.github.com/users/eddyb/orgs","repos_url":"https://api.github.com/users/eddyb/repos","events_url":"https://api.github.com/users/eddyb/events{/privacy}","received_events_url":"https://api.github.com/users/eddyb/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":583426710,"url":"https://api.github.com/repos/rust-lang/rust/labels/S-waiting-on-review","name":"S-waiting-on-review","color":"d3dddd","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/rust-lang/rust/pulls/49878/commits","review_comments_url":"https://api.github.com/repos/rust-lang/rust/pulls/49878/comments","review_comment_url":"https://api.github.com/repos/rust-lang/rust/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/49878/comments","statuses_url":"https://api.github.com/repos/rust-lang/rust/statuses/fbf2ad3973ffa5270cd0aa8f08c37045192ed6ad","head":{"label":"dlrobertson:va_list_pt0","ref":"va_list_pt0","sha":"fbf2ad3973ffa5270cd0aa8f08c37045192ed6ad","user":{"login":"dlrobertson","id":7504153,"avatar_url":"https://avatars1.githubusercontent.com/u/7504153?v=4","gravatar_id":"","url":"https://api.github.com/users/dlrobertson","html_url":"https://github.com/dlrobertson","followers_url":"https://api.github.com/users/dlrobertson/followers","following_url":"https://api.github.com/users/dlrobertson/following{/other_user}","gists_url":"https://api.github.com/users/dlrobertson/gists{/gist_id}","starred_url":"https://api.github.com/users/dlrobertson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlrobertson/subscriptions","organizations_url":"https://api.github.com/users/dlrobertson/orgs","repos_url":"https://api.github.com/users/dlrobertson/repos","events_url":"https://api.github.com/users/dlrobertson/events{/privacy}","received_events_url":"https://api.github.com/users/dlrobertson/received_events","type":"User","site_admin":false},"repo":{"id":51410478,"name":"rust","full_name":"dlrobertson/rust","owner":{"login":"dlrobertson","id":7504153,"avatar_url":"https://avatars1.githubusercontent.com/u/7504153?v=4","gravatar_id":"","url":"https://api.github.com/users/dlrobertson","html_url":"https://github.com/dlrobertson","followers_url":"https://api.github.com/users/dlrobertson/followers","following_url":"https://api.github.com/users/dlrobertson/following{/other_user}","gists_url":"https://api.github.com/users/dlrobertson/gists{/gist_id}","starred_url":"https://api.github.com/users/dlrobertson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlrobertson/subscriptions","organizations_url":"https://api.github.com/users/dlrobertson/orgs","repos_url":"https://api.github.com/users/dlrobertson/repos","events_url":"https://api.github.com/users/dlrobertson/events{/privacy}","received_events_url":"https://api.github.com/users/dlrobertson/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dlrobertson/rust","description":"A safe, concurrent, practical language.","fork":true,"url":"https://api.github.com/repos/dlrobertson/rust","forks_url":"https://api.github.com/repos/dlrobertson/rust/forks","keys_url":"https://api.github.com/repos/dlrobertson/rust/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dlrobertson/rust/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dlrobertson/rust/teams","hooks_url":"https://api.github.com/repos/dlrobertson/rust/hooks","issue_events_url":"https://api.github.com/repos/dlrobertson/rust/issues/events{/number}","events_url":"https://api.github.com/repos/dlrobertson/rust/events","assignees_url":"https://api.github.com/repos/dlrobertson/rust/assignees{/user}","branches_url":"https://api.github.com/repos/dlrobertson/rust/branches{/branch}","tags_url":"https://api.github.com/repos/dlrobertson/rust/tags","blobs_url":"https://api.github.com/repos/dlrobertson/rust/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dlrobertson/rust/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dlrobertson/rust/git/refs{/sha}","trees_url":"https://api.github.com/repos/dlrobertson/rust/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dlrobertson/rust/statuses/{sha}","languages_url":"https://api.github.com/repos/dlrobertson/rust/languages","stargazers_url":"https://api.github.com/repos/dlrobertson/rust/stargazers","contributors_url":"https://api.github.com/repos/dlrobertson/rust/contributors","subscribers_url":"https://api.github.com/repos/dlrobertson/rust/subscribers","subscription_url":"https://api.github.com/repos/dlrobertson/rust/subscription","commits_url":"https://api.github.com/repos/dlrobertson/rust/commits{/sha}","git_commits_url":"https://api.github.com/repos/dlrobertson/rust/git/commits{/sha}","comments_url":"https://api.github.com/repos/dlrobertson/rust/comments{/number}","issue_comment_url":"https://api.github.com/repos/dlrobertson/rust/issues/comments{/number}","contents_url":"https://api.github.com/repos/dlrobertson/rust/contents/{+path}","compare_url":"https://api.github.com/repos/dlrobertson/rust/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dlrobertson/rust/merges","archive_url":"https://api.github.com/repos/dlrobertson/rust/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dlrobertson/rust/downloads","issues_url":"https://api.github.com/repos/dlrobertson/rust/issues{/number}","pulls_url":"https://api.github.com/repos/dlrobertson/rust/pulls{/number}","milestones_url":"https://api.github.com/repos/dlrobertson/rust/milestones{/number}","notifications_url":"https://api.github.com/repos/dlrobertson/rust/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dlrobertson/rust/labels{/name}","releases_url":"https://api.github.com/repos/dlrobertson/rust/releases{/id}","deployments_url":"https://api.github.com/repos/dlrobertson/rust/deployments","created_at":"2016-02-10T00:03:58Z","updated_at":"2018-05-15T11:47:35Z","pushed_at":"2018-05-15T11:47:29Z","git_url":"git://github.com/dlrobertson/rust.git","ssh_url":"git@github.com:dlrobertson/rust.git","clone_url":"https://github.com/dlrobertson/rust.git","svn_url":"https://github.com/dlrobertson/rust","homepage":"http://www.rust-lang.org","size":366493,"stargazers_count":0,"watchers_count":0,"language":"Rust","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"rust-lang:master","ref":"master","sha":"715d6a98aa4908dfb85b55f97e51af330d0baf7f","user":{"login":"rust-lang","id":5430905,"avatar_url":"https://avatars1.githubusercontent.com/u/5430905?v=4","gravatar_id":"","url":"https://api.github.com/users/rust-lang","html_url":"https://github.com/rust-lang","followers_url":"https://api.github.com/users/rust-lang/followers","following_url":"https://api.github.com/users/rust-lang/following{/other_user}","gists_url":"https://api.github.com/users/rust-lang/gists{/gist_id}","starred_url":"https://api.github.com/users/rust-lang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rust-lang/subscriptions","organizations_url":"https://api.github.com/users/rust-lang/orgs","repos_url":"https://api.github.com/users/rust-lang/repos","events_url":"https://api.github.com/users/rust-lang/events{/privacy}","received_events_url":"https://api.github.com/users/rust-lang/received_events","type":"Organization","site_admin":false},"repo":{"id":724712,"name":"rust","full_name":"rust-lang/rust","owner":{"login":"rust-lang","id":5430905,"avatar_url":"https://avatars1.githubusercontent.com/u/5430905?v=4","gravatar_id":"","url":"https://api.github.com/users/rust-lang","html_url":"https://github.com/rust-lang","followers_url":"https://api.github.com/users/rust-lang/followers","following_url":"https://api.github.com/users/rust-lang/following{/other_user}","gists_url":"https://api.github.com/users/rust-lang/gists{/gist_id}","starred_url":"https://api.github.com/users/rust-lang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rust-lang/subscriptions","organizations_url":"https://api.github.com/users/rust-lang/orgs","repos_url":"https://api.github.com/users/rust-lang/repos","events_url":"https://api.github.com/users/rust-lang/events{/privacy}","received_events_url":"https://api.github.com/users/rust-lang/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/rust-lang/rust","description":"A safe, concurrent, practical language.","fork":false,"url":"https://api.github.com/repos/rust-lang/rust","forks_url":"https://api.github.com/repos/rust-lang/rust/forks","keys_url":"https://api.github.com/repos/rust-lang/rust/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rust-lang/rust/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rust-lang/rust/teams","hooks_url":"https://api.github.com/repos/rust-lang/rust/hooks","issue_events_url":"https://api.github.com/repos/rust-lang/rust/issues/events{/number}","events_url":"https://api.github.com/repos/rust-lang/rust/events","assignees_url":"https://api.github.com/repos/rust-lang/rust/assignees{/user}","branches_url":"https://api.github.com/repos/rust-lang/rust/branches{/branch}","tags_url":"https://api.github.com/repos/rust-lang/rust/tags","blobs_url":"https://api.github.com/repos/rust-lang/rust/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rust-lang/rust/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rust-lang/rust/git/refs{/sha}","trees_url":"https://api.github.com/repos/rust-lang/rust/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rust-lang/rust/statuses/{sha}","languages_url":"https://api.github.com/repos/rust-lang/rust/languages","stargazers_url":"https://api.github.com/repos/rust-lang/rust/stargazers","contributors_url":"https://api.github.com/repos/rust-lang/rust/contributors","subscribers_url":"https://api.github.com/repos/rust-lang/rust/subscribers","subscription_url":"https://api.github.com/repos/rust-lang/rust/subscription","commits_url":"https://api.github.com/repos/rust-lang/rust/commits{/sha}","git_commits_url":"https://api.github.com/repos/rust-lang/rust/git/commits{/sha}","comments_url":"https://api.github.com/repos/rust-lang/rust/comments{/number}","issue_comment_url":"https://api.github.com/repos/rust-lang/rust/issues/comments{/number}","contents_url":"https://api.github.com/repos/rust-lang/rust/contents/{+path}","compare_url":"https://api.github.com/repos/rust-lang/rust/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rust-lang/rust/merges","archive_url":"https://api.github.com/repos/rust-lang/rust/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rust-lang/rust/downloads","issues_url":"https://api.github.com/repos/rust-lang/rust/issues{/number}","pulls_url":"https://api.github.com/repos/rust-lang/rust/pulls{/number}","milestones_url":"https://api.github.com/repos/rust-lang/rust/milestones{/number}","notifications_url":"https://api.github.com/repos/rust-lang/rust/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rust-lang/rust/labels{/name}","releases_url":"https://api.github.com/repos/rust-lang/rust/releases{/id}","deployments_url":"https://api.github.com/repos/rust-lang/rust/deployments","created_at":"2010-06-16T20:39:03Z","updated_at":"2018-05-16T04:00:51Z","pushed_at":"2018-05-16T05:27:41Z","git_url":"git://github.com/rust-lang/rust.git","ssh_url":"git@github.com:rust-lang/rust.git","clone_url":"https://github.com/rust-lang/rust.git","svn_url":"https://github.com/rust-lang/rust","homepage":"https://www.rust-lang.org","size":369875,"stargazers_count":28250,"watchers_count":28250,"language":"Rust","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":4913,"mirror_url":null,"archived":false,"open_issues_count":3802,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":4913,"open_issues":3802,"watchers":28250,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/49878"},"html":{"href":"https://github.com/rust-lang/rust/pull/49878"},"issue":{"href":"https://api.github.com/repos/rust-lang/rust/issues/49878"},"comments":{"href":"https://api.github.com/repos/rust-lang/rust/issues/49878/comments"},"review_comments":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/49878/comments"},"review_comment":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/49878/commits"},"statuses":{"href":"https://api.github.com/repos/rust-lang/rust/statuses/fbf2ad3973ffa5270cd0aa8f08c37045192ed6ad"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"eddyb"}}