{"action":"created","issue":{"url":"https://api.github.com/repos/dotnet/corefx/issues/1401","labels_url":"https://api.github.com/repos/dotnet/corefx/issues/1401/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/corefx/issues/1401/comments","events_url":"https://api.github.com/repos/dotnet/corefx/issues/1401/events","html_url":"https://github.com/dotnet/corefx/pull/1401","id":68246546,"number":1401,"title":"Make ImmutableArray's SyncRoot throw NotSupportedException","user":{"login":"stephentoub","id":2642209,"avatar_url":"https://avatars.githubusercontent.com/u/2642209?v=3","gravatar_id":"","url":"https://api.github.com/users/stephentoub","html_url":"https://github.com/stephentoub","followers_url":"https://api.github.com/users/stephentoub/followers","following_url":"https://api.github.com/users/stephentoub/following{/other_user}","gists_url":"https://api.github.com/users/stephentoub/gists{/gist_id}","starred_url":"https://api.github.com/users/stephentoub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephentoub/subscriptions","organizations_url":"https://api.github.com/users/stephentoub/orgs","repos_url":"https://api.github.com/users/stephentoub/repos","events_url":"https://api.github.com/users/stephentoub/events{/privacy}","received_events_url":"https://api.github.com/users/stephentoub/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/dotnet/corefx/labels/2%20-%20In%20Progress","name":"2 - In Progress","color":"CCCCCC"},{"url":"https://api.github.com/repos/dotnet/corefx/labels/cla-already-signed","name":"cla-already-signed","color":"009800"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-04-14T02:57:21Z","updated_at":"2015-04-15T15:12:14Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/dotnet/corefx/pulls/1401","html_url":"https://github.com/dotnet/corefx/pull/1401","diff_url":"https://github.com/dotnet/corefx/pull/1401.diff","patch_url":"https://github.com/dotnet/corefx/pull/1401.patch"},"body":"ImmutableArray<T>'s ICollection.SyncRoot implementation currently does \"return this;\".  Unfortunately, this will result in returning a new object each time, which means that any attempts to use the resulting object to synchronize blocks of arbitrary code will silently result in race conditions as different objects end up being used.  With ImmutableArray<T> being a single-field struct, and with it being a violation of its design to return the underlying array as the sync root, the best available option is to simply throw a NotSupportedException.\r\n\r\nFixes #1390."},"comment":{"url":"https://api.github.com/repos/dotnet/corefx/issues/comments/93440315","html_url":"https://github.com/dotnet/corefx/pull/1401#issuecomment-93440315","issue_url":"https://api.github.com/repos/dotnet/corefx/issues/1401","id":93440315,"user":{"login":"terrajobst","id":5169960,"avatar_url":"https://avatars.githubusercontent.com/u/5169960?v=3","gravatar_id":"","url":"https://api.github.com/users/terrajobst","html_url":"https://github.com/terrajobst","followers_url":"https://api.github.com/users/terrajobst/followers","following_url":"https://api.github.com/users/terrajobst/following{/other_user}","gists_url":"https://api.github.com/users/terrajobst/gists{/gist_id}","starred_url":"https://api.github.com/users/terrajobst/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/terrajobst/subscriptions","organizations_url":"https://api.github.com/users/terrajobst/orgs","repos_url":"https://api.github.com/users/terrajobst/repos","events_url":"https://api.github.com/users/terrajobst/events{/privacy}","received_events_url":"https://api.github.com/users/terrajobst/received_events","type":"User","site_admin":false},"created_at":"2015-04-15T15:12:14Z","updated_at":"2015-04-15T15:12:14Z","body":"LGTM"}}