{"action":"created","comment":{"url":"https://api.github.com/repos/dlang/dmd/pulls/comments/175041824","pull_request_review_id":104507867,"id":175041824,"diff_hunk":"@@ -3223,7 +3223,16 @@ private extern(C++) final class DotExpVisitor : Visitor\n                 }\n                 checkAccess(e.loc, sc, null, v);\n                 Expression ve = new VarExp(e.loc, v);\n-                ve = ve.expressionSemantic(sc);\n+                if (e.op == TOK.type || e.op == TOK.this_ || e.op == TOK.super_ || e.op == TOK.variable)\n+                {\n+                    ve = ve.expressionSemantic(sc);","path":"src/dmd/typesem.d","position":7,"original_position":7,"commit_id":"be22c7dee58efe279a36987ef4ab8c4387091abf","original_commit_id":"be22c7dee58efe279a36987ef4ab8c4387091abf","user":{"login":"RazvanN7","id":22907766,"avatar_url":"https://avatars2.githubusercontent.com/u/22907766?v=4","gravatar_id":"","url":"https://api.github.com/users/RazvanN7","html_url":"https://github.com/RazvanN7","followers_url":"https://api.github.com/users/RazvanN7/followers","following_url":"https://api.github.com/users/RazvanN7/following{/other_user}","gists_url":"https://api.github.com/users/RazvanN7/gists{/gist_id}","starred_url":"https://api.github.com/users/RazvanN7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RazvanN7/subscriptions","organizations_url":"https://api.github.com/users/RazvanN7/orgs","repos_url":"https://api.github.com/users/RazvanN7/repos","events_url":"https://api.github.com/users/RazvanN7/events{/privacy}","received_events_url":"https://api.github.com/users/RazvanN7/received_events","type":"User","site_admin":false},"body":"Please add this explanation as a comment in the code. It will be useful in the future when people will try to understand the code.","created_at":"2018-03-16T09:58:10Z","updated_at":"2018-03-16T09:58:26Z","html_url":"https://github.com/dlang/dmd/pull/8013#discussion_r175041824","pull_request_url":"https://api.github.com/repos/dlang/dmd/pulls/8013","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/dlang/dmd/pulls/comments/175041824"},"html":{"href":"https://github.com/dlang/dmd/pull/8013#discussion_r175041824"},"pull_request":{"href":"https://api.github.com/repos/dlang/dmd/pulls/8013"}},"in_reply_to_id":174390809},"pull_request":{"url":"https://api.github.com/repos/dlang/dmd/pulls/8013","id":174319730,"html_url":"https://github.com/dlang/dmd/pull/8013","diff_url":"https://github.com/dlang/dmd/pull/8013.diff","patch_url":"https://github.com/dlang/dmd/pull/8013.patch","issue_url":"https://api.github.com/repos/dlang/dmd/issues/8013","number":8013,"state":"open","locked":false,"title":"fix Issue 12486 - Function returning struct isn't called if `enum` of its result is accessed","user":{"login":"FeepingCreature","id":540727,"avatar_url":"https://avatars2.githubusercontent.com/u/540727?v=4","gravatar_id":"","url":"https://api.github.com/users/FeepingCreature","html_url":"https://github.com/FeepingCreature","followers_url":"https://api.github.com/users/FeepingCreature/followers","following_url":"https://api.github.com/users/FeepingCreature/following{/other_user}","gists_url":"https://api.github.com/users/FeepingCreature/gists{/gist_id}","starred_url":"https://api.github.com/users/FeepingCreature/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FeepingCreature/subscriptions","organizations_url":"https://api.github.com/users/FeepingCreature/orgs","repos_url":"https://api.github.com/users/FeepingCreature/repos","events_url":"https://api.github.com/users/FeepingCreature/events{/privacy}","received_events_url":"https://api.github.com/users/FeepingCreature/received_events","type":"User","site_admin":false},"body":"Fix issue 12486\r\n\r\nWhen accessing an enum member of a struct returned by an expression with side effects, don't discard the expression but evaluate it anyways. (No, this is not safe even if the expression is pure: it might loop infinitely.)","created_at":"2018-03-12T10:03:17Z","updated_at":"2018-03-16T09:58:26Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3cd92fc2c236ab03a2f0f110c08d4429c7909e46","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/dlang/dmd/pulls/8013/commits","review_comments_url":"https://api.github.com/repos/dlang/dmd/pulls/8013/comments","review_comment_url":"https://api.github.com/repos/dlang/dmd/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dlang/dmd/issues/8013/comments","statuses_url":"https://api.github.com/repos/dlang/dmd/statuses/be22c7dee58efe279a36987ef4ab8c4387091abf","head":{"label":"FeepingCreature:fix/12486-dont-discard-expression-on-enum-access","ref":"fix/12486-dont-discard-expression-on-enum-access","sha":"be22c7dee58efe279a36987ef4ab8c4387091abf","user":{"login":"FeepingCreature","id":540727,"avatar_url":"https://avatars2.githubusercontent.com/u/540727?v=4","gravatar_id":"","url":"https://api.github.com/users/FeepingCreature","html_url":"https://github.com/FeepingCreature","followers_url":"https://api.github.com/users/FeepingCreature/followers","following_url":"https://api.github.com/users/FeepingCreature/following{/other_user}","gists_url":"https://api.github.com/users/FeepingCreature/gists{/gist_id}","starred_url":"https://api.github.com/users/FeepingCreature/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FeepingCreature/subscriptions","organizations_url":"https://api.github.com/users/FeepingCreature/orgs","repos_url":"https://api.github.com/users/FeepingCreature/repos","events_url":"https://api.github.com/users/FeepingCreature/events{/privacy}","received_events_url":"https://api.github.com/users/FeepingCreature/received_events","type":"User","site_admin":false},"repo":{"id":108558698,"name":"dmd","full_name":"FeepingCreature/dmd","owner":{"login":"FeepingCreature","id":540727,"avatar_url":"https://avatars2.githubusercontent.com/u/540727?v=4","gravatar_id":"","url":"https://api.github.com/users/FeepingCreature","html_url":"https://github.com/FeepingCreature","followers_url":"https://api.github.com/users/FeepingCreature/followers","following_url":"https://api.github.com/users/FeepingCreature/following{/other_user}","gists_url":"https://api.github.com/users/FeepingCreature/gists{/gist_id}","starred_url":"https://api.github.com/users/FeepingCreature/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FeepingCreature/subscriptions","organizations_url":"https://api.github.com/users/FeepingCreature/orgs","repos_url":"https://api.github.com/users/FeepingCreature/repos","events_url":"https://api.github.com/users/FeepingCreature/events{/privacy}","received_events_url":"https://api.github.com/users/FeepingCreature/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/FeepingCreature/dmd","description":"dmd D Programming Language compiler","fork":true,"url":"https://api.github.com/repos/FeepingCreature/dmd","forks_url":"https://api.github.com/repos/FeepingCreature/dmd/forks","keys_url":"https://api.github.com/repos/FeepingCreature/dmd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/FeepingCreature/dmd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/FeepingCreature/dmd/teams","hooks_url":"https://api.github.com/repos/FeepingCreature/dmd/hooks","issue_events_url":"https://api.github.com/repos/FeepingCreature/dmd/issues/events{/number}","events_url":"https://api.github.com/repos/FeepingCreature/dmd/events","assignees_url":"https://api.github.com/repos/FeepingCreature/dmd/assignees{/user}","branches_url":"https://api.github.com/repos/FeepingCreature/dmd/branches{/branch}","tags_url":"https://api.github.com/repos/FeepingCreature/dmd/tags","blobs_url":"https://api.github.com/repos/FeepingCreature/dmd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/FeepingCreature/dmd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/FeepingCreature/dmd/git/refs{/sha}","trees_url":"https://api.github.com/repos/FeepingCreature/dmd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/FeepingCreature/dmd/statuses/{sha}","languages_url":"https://api.github.com/repos/FeepingCreature/dmd/languages","stargazers_url":"https://api.github.com/repos/FeepingCreature/dmd/stargazers","contributors_url":"https://api.github.com/repos/FeepingCreature/dmd/contributors","subscribers_url":"https://api.github.com/repos/FeepingCreature/dmd/subscribers","subscription_url":"https://api.github.com/repos/FeepingCreature/dmd/subscription","commits_url":"https://api.github.com/repos/FeepingCreature/dmd/commits{/sha}","git_commits_url":"https://api.github.com/repos/FeepingCreature/dmd/git/commits{/sha}","comments_url":"https://api.github.com/repos/FeepingCreature/dmd/comments{/number}","issue_comment_url":"https://api.github.com/repos/FeepingCreature/dmd/issues/comments{/number}","contents_url":"https://api.github.com/repos/FeepingCreature/dmd/contents/{+path}","compare_url":"https://api.github.com/repos/FeepingCreature/dmd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/FeepingCreature/dmd/merges","archive_url":"https://api.github.com/repos/FeepingCreature/dmd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/FeepingCreature/dmd/downloads","issues_url":"https://api.github.com/repos/FeepingCreature/dmd/issues{/number}","pulls_url":"https://api.github.com/repos/FeepingCreature/dmd/pulls{/number}","milestones_url":"https://api.github.com/repos/FeepingCreature/dmd/milestones{/number}","notifications_url":"https://api.github.com/repos/FeepingCreature/dmd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/FeepingCreature/dmd/labels{/name}","releases_url":"https://api.github.com/repos/FeepingCreature/dmd/releases{/id}","deployments_url":"https://api.github.com/repos/FeepingCreature/dmd/deployments","created_at":"2017-10-27T14:49:37Z","updated_at":"2017-10-27T14:49:44Z","pushed_at":"2018-03-14T08:55:25Z","git_url":"git://github.com/FeepingCreature/dmd.git","ssh_url":"git@github.com:FeepingCreature/dmd.git","clone_url":"https://github.com/FeepingCreature/dmd.git","svn_url":"https://github.com/FeepingCreature/dmd","homepage":"dlang.org","size":85741,"stargazers_count":0,"watchers_count":0,"language":"D","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":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"dlang:master","ref":"master","sha":"546a78d580e51a32b41396662a2f5511e0a779c1","user":{"login":"dlang","id":565913,"avatar_url":"https://avatars3.githubusercontent.com/u/565913?v=4","gravatar_id":"","url":"https://api.github.com/users/dlang","html_url":"https://github.com/dlang","followers_url":"https://api.github.com/users/dlang/followers","following_url":"https://api.github.com/users/dlang/following{/other_user}","gists_url":"https://api.github.com/users/dlang/gists{/gist_id}","starred_url":"https://api.github.com/users/dlang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlang/subscriptions","organizations_url":"https://api.github.com/users/dlang/orgs","repos_url":"https://api.github.com/users/dlang/repos","events_url":"https://api.github.com/users/dlang/events{/privacy}","received_events_url":"https://api.github.com/users/dlang/received_events","type":"Organization","site_admin":false},"repo":{"id":1257070,"name":"dmd","full_name":"dlang/dmd","owner":{"login":"dlang","id":565913,"avatar_url":"https://avatars3.githubusercontent.com/u/565913?v=4","gravatar_id":"","url":"https://api.github.com/users/dlang","html_url":"https://github.com/dlang","followers_url":"https://api.github.com/users/dlang/followers","following_url":"https://api.github.com/users/dlang/following{/other_user}","gists_url":"https://api.github.com/users/dlang/gists{/gist_id}","starred_url":"https://api.github.com/users/dlang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlang/subscriptions","organizations_url":"https://api.github.com/users/dlang/orgs","repos_url":"https://api.github.com/users/dlang/repos","events_url":"https://api.github.com/users/dlang/events{/privacy}","received_events_url":"https://api.github.com/users/dlang/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dlang/dmd","description":"dmd D Programming Language compiler","fork":false,"url":"https://api.github.com/repos/dlang/dmd","forks_url":"https://api.github.com/repos/dlang/dmd/forks","keys_url":"https://api.github.com/repos/dlang/dmd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dlang/dmd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dlang/dmd/teams","hooks_url":"https://api.github.com/repos/dlang/dmd/hooks","issue_events_url":"https://api.github.com/repos/dlang/dmd/issues/events{/number}","events_url":"https://api.github.com/repos/dlang/dmd/events","assignees_url":"https://api.github.com/repos/dlang/dmd/assignees{/user}","branches_url":"https://api.github.com/repos/dlang/dmd/branches{/branch}","tags_url":"https://api.github.com/repos/dlang/dmd/tags","blobs_url":"https://api.github.com/repos/dlang/dmd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dlang/dmd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dlang/dmd/git/refs{/sha}","trees_url":"https://api.github.com/repos/dlang/dmd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dlang/dmd/statuses/{sha}","languages_url":"https://api.github.com/repos/dlang/dmd/languages","stargazers_url":"https://api.github.com/repos/dlang/dmd/stargazers","contributors_url":"https://api.github.com/repos/dlang/dmd/contributors","subscribers_url":"https://api.github.com/repos/dlang/dmd/subscribers","subscription_url":"https://api.github.com/repos/dlang/dmd/subscription","commits_url":"https://api.github.com/repos/dlang/dmd/commits{/sha}","git_commits_url":"https://api.github.com/repos/dlang/dmd/git/commits{/sha}","comments_url":"https://api.github.com/repos/dlang/dmd/comments{/number}","issue_comment_url":"https://api.github.com/repos/dlang/dmd/issues/comments{/number}","contents_url":"https://api.github.com/repos/dlang/dmd/contents/{+path}","compare_url":"https://api.github.com/repos/dlang/dmd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dlang/dmd/merges","archive_url":"https://api.github.com/repos/dlang/dmd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dlang/dmd/downloads","issues_url":"https://api.github.com/repos/dlang/dmd/issues{/number}","pulls_url":"https://api.github.com/repos/dlang/dmd/pulls{/number}","milestones_url":"https://api.github.com/repos/dlang/dmd/milestones{/number}","notifications_url":"https://api.github.com/repos/dlang/dmd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dlang/dmd/labels{/name}","releases_url":"https://api.github.com/repos/dlang/dmd/releases{/id}","deployments_url":"https://api.github.com/repos/dlang/dmd/deployments","created_at":"2011-01-15T06:53:53Z","updated_at":"2018-03-16T05:18:13Z","pushed_at":"2018-03-16T09:04:42Z","git_url":"git://github.com/dlang/dmd.git","ssh_url":"git@github.com:dlang/dmd.git","clone_url":"https://github.com/dlang/dmd.git","svn_url":"https://github.com/dlang/dmd","homepage":"dlang.org","size":87093,"stargazers_count":1760,"watchers_count":1760,"language":"D","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":441,"mirror_url":null,"archived":false,"open_issues_count":147,"license":{"key":"bsl-1.0","name":"Boost Software License 1.0","spdx_id":"BSL-1.0","url":"https://api.github.com/licenses/bsl-1.0"},"forks":441,"open_issues":147,"watchers":1760,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dlang/dmd/pulls/8013"},"html":{"href":"https://github.com/dlang/dmd/pull/8013"},"issue":{"href":"https://api.github.com/repos/dlang/dmd/issues/8013"},"comments":{"href":"https://api.github.com/repos/dlang/dmd/issues/8013/comments"},"review_comments":{"href":"https://api.github.com/repos/dlang/dmd/pulls/8013/comments"},"review_comment":{"href":"https://api.github.com/repos/dlang/dmd/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dlang/dmd/pulls/8013/commits"},"statuses":{"href":"https://api.github.com/repos/dlang/dmd/statuses/be22c7dee58efe279a36987ef4ab8c4387091abf"}},"author_association":"NONE"}}
{"actor":{"display_login":"RazvanN7"}}