{"action":"created","issue":{"url":"https://api.github.com/repos/dotnet/roslyn/issues/1867","labels_url":"https://api.github.com/repos/dotnet/roslyn/issues/1867/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/roslyn/issues/1867/comments","events_url":"https://api.github.com/repos/dotnet/roslyn/issues/1867/events","html_url":"https://github.com/dotnet/roslyn/issues/1867","id":67195479,"number":1867,"title":"Have compiler return semantic errors in lambdas even in the presence of syntax errors","user":{"login":"jmarolf","id":9797472,"avatar_url":"https://avatars.githubusercontent.com/u/9797472?v=3","gravatar_id":"","url":"https://api.github.com/users/jmarolf","html_url":"https://github.com/jmarolf","followers_url":"https://api.github.com/users/jmarolf/followers","following_url":"https://api.github.com/users/jmarolf/following{/other_user}","gists_url":"https://api.github.com/users/jmarolf/gists{/gist_id}","starred_url":"https://api.github.com/users/jmarolf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmarolf/subscriptions","organizations_url":"https://api.github.com/users/jmarolf/orgs","repos_url":"https://api.github.com/users/jmarolf/repos","events_url":"https://api.github.com/users/jmarolf/events{/privacy}","received_events_url":"https://api.github.com/users/jmarolf/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/dotnet/roslyn/labels/4%20-%20In%20Review","name":"4 - In Review","color":"CCCCCC"},{"url":"https://api.github.com/repos/dotnet/roslyn/labels/Area-Compilers","name":"Area-Compilers","color":"5319e7"},{"url":"https://api.github.com/repos/dotnet/roslyn/labels/Concept-API","name":"Concept-API","color":"fef2c0"},{"url":"https://api.github.com/repos/dotnet/roslyn/labels/Concept-Diagnostic%20Clarity","name":"Concept-Diagnostic Clarity","color":"fef2c0"},{"url":"https://api.github.com/repos/dotnet/roslyn/labels/Feature%20Request","name":"Feature Request","color":"fc2929"}],"state":"closed","locked":false,"assignee":{"login":"gafter","id":3804346,"avatar_url":"https://avatars.githubusercontent.com/u/3804346?v=3","gravatar_id":"","url":"https://api.github.com/users/gafter","html_url":"https://github.com/gafter","followers_url":"https://api.github.com/users/gafter/followers","following_url":"https://api.github.com/users/gafter/following{/other_user}","gists_url":"https://api.github.com/users/gafter/gists{/gist_id}","starred_url":"https://api.github.com/users/gafter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gafter/subscriptions","organizations_url":"https://api.github.com/users/gafter/orgs","repos_url":"https://api.github.com/users/gafter/repos","events_url":"https://api.github.com/users/gafter/events{/privacy}","received_events_url":"https://api.github.com/users/gafter/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/dotnet/roslyn/milestones/4","html_url":"https://github.com/dotnet/roslyn/milestones/1.2","labels_url":"https://api.github.com/repos/dotnet/roslyn/milestones/4/labels","id":937402,"number":4,"title":"1.2","description":"This is our 1.2 Milestone.\r\n\r\n<!---\r\n@huboard:{\"order\":2.0}\r\n-->\r\n","creator":{"login":"jaredpar","id":146967,"avatar_url":"https://avatars.githubusercontent.com/u/146967?v=3","gravatar_id":"","url":"https://api.github.com/users/jaredpar","html_url":"https://github.com/jaredpar","followers_url":"https://api.github.com/users/jaredpar/followers","following_url":"https://api.github.com/users/jaredpar/following{/other_user}","gists_url":"https://api.github.com/users/jaredpar/gists{/gist_id}","starred_url":"https://api.github.com/users/jaredpar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaredpar/subscriptions","organizations_url":"https://api.github.com/users/jaredpar/orgs","repos_url":"https://api.github.com/users/jaredpar/repos","events_url":"https://api.github.com/users/jaredpar/events{/privacy}","received_events_url":"https://api.github.com/users/jaredpar/received_events","type":"User","site_admin":false},"open_issues":604,"closed_issues":305,"state":"open","created_at":"2015-01-15T20:48:55Z","updated_at":"2015-12-30T06:36:54Z","due_on":null,"closed_at":null},"comments":7,"created_at":"2015-04-08T18:57:11Z","updated_at":"2015-12-30T06:37:59Z","closed_at":"2015-12-30T06:36:54Z","body":"Today, the compiler does not return semantic errors inside lambdas in the IDE if there are syntax errors.   This causes several quick fix scenarios to fail inside lambdas (for example #1239, #1241, and #1744 are all caused by this problem).  \r\n\r\nConsider the code sample below from issue #1239:\r\n```C#\r\nusing System.Threading.Tasks;\r\n\r\nclass C {\r\n    C() {\r\n        Task.Run(() => {\r\n            new C(0)\r\n        });\r\n    }\r\n}\r\n```\r\n\r\n_new C(0)_ will never be squiggled by the IDE because of the lack of a semicolon.  This makes quick-fixes that could generate a constructor unable to run because there is no error to trigger them.  \r\n\r\nBy having the compiler return semantic errors in lambdas even in the presence of syntax errors, many more IDE scenarios will \"Just Work\" \r\n\r\n<!---\r\n@huboard:{\"order\":415.359375,\"milestone_order\":1867,\"custom_state\":\"\"}\n-->\r\n"},"comment":{"url":"https://api.github.com/repos/dotnet/roslyn/issues/comments/167945955","html_url":"https://github.com/dotnet/roslyn/issues/1867#issuecomment-167945955","issue_url":"https://api.github.com/repos/dotnet/roslyn/issues/1867","id":167945955,"user":{"login":"gafter","id":3804346,"avatar_url":"https://avatars.githubusercontent.com/u/3804346?v=3","gravatar_id":"","url":"https://api.github.com/users/gafter","html_url":"https://github.com/gafter","followers_url":"https://api.github.com/users/gafter/followers","following_url":"https://api.github.com/users/gafter/following{/other_user}","gists_url":"https://api.github.com/users/gafter/gists{/gist_id}","starred_url":"https://api.github.com/users/gafter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gafter/subscriptions","organizations_url":"https://api.github.com/users/gafter/orgs","repos_url":"https://api.github.com/users/gafter/repos","events_url":"https://api.github.com/users/gafter/events{/privacy}","received_events_url":"https://api.github.com/users/gafter/received_events","type":"User","site_admin":false},"created_at":"2015-12-30T06:37:59Z","updated_at":"2015-12-30T06:37:59Z","body":"@CyrusNajmabadi OK, all fixed. I'm eager to catch as many of these cases as possible. You're welcome to open *new issues* for any new cases you discover."}}