{"action":"created","issue":{"url":"https://api.github.com/repos/dotnet/corefx/issues/5422","labels_url":"https://api.github.com/repos/dotnet/corefx/issues/5422/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/corefx/issues/5422/comments","events_url":"https://api.github.com/repos/dotnet/corefx/issues/5422/events","html_url":"https://github.com/dotnet/corefx/issues/5422","id":126709691,"number":5422,"title":"[Bug] Portable Class Library compilation gets broken when a target is _removed_","user":{"login":"tzwlai","id":9966807,"avatar_url":"https://avatars.githubusercontent.com/u/9966807?v=3","gravatar_id":"","url":"https://api.github.com/users/tzwlai","html_url":"https://github.com/tzwlai","followers_url":"https://api.github.com/users/tzwlai/followers","following_url":"https://api.github.com/users/tzwlai/following{/other_user}","gists_url":"https://api.github.com/users/tzwlai/gists{/gist_id}","starred_url":"https://api.github.com/users/tzwlai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tzwlai/subscriptions","organizations_url":"https://api.github.com/users/tzwlai/orgs","repos_url":"https://api.github.com/users/tzwlai/repos","events_url":"https://api.github.com/users/tzwlai/events{/privacy}","received_events_url":"https://api.github.com/users/tzwlai/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/dotnet/corefx/labels/Infrastructure","name":"Infrastructure","color":"fbca04"}],"state":"open","locked":false,"assignee":{"login":"weshaggard","id":9010698,"avatar_url":"https://avatars.githubusercontent.com/u/9010698?v=3","gravatar_id":"","url":"https://api.github.com/users/weshaggard","html_url":"https://github.com/weshaggard","followers_url":"https://api.github.com/users/weshaggard/followers","following_url":"https://api.github.com/users/weshaggard/following{/other_user}","gists_url":"https://api.github.com/users/weshaggard/gists{/gist_id}","starred_url":"https://api.github.com/users/weshaggard/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weshaggard/subscriptions","organizations_url":"https://api.github.com/users/weshaggard/orgs","repos_url":"https://api.github.com/users/weshaggard/repos","events_url":"https://api.github.com/users/weshaggard/events{/privacy}","received_events_url":"https://api.github.com/users/weshaggard/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/dotnet/corefx/milestones/6","html_url":"https://github.com/dotnet/corefx/milestones/1.0.0-rc2","labels_url":"https://api.github.com/repos/dotnet/corefx/milestones/6/labels","id":1365455,"number":6,"title":"1.0.0-rc2","description":"","creator":{"login":"joshfree","id":1302850,"avatar_url":"https://avatars.githubusercontent.com/u/1302850?v=3","gravatar_id":"","url":"https://api.github.com/users/joshfree","html_url":"https://github.com/joshfree","followers_url":"https://api.github.com/users/joshfree/followers","following_url":"https://api.github.com/users/joshfree/following{/other_user}","gists_url":"https://api.github.com/users/joshfree/gists{/gist_id}","starred_url":"https://api.github.com/users/joshfree/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joshfree/subscriptions","organizations_url":"https://api.github.com/users/joshfree/orgs","repos_url":"https://api.github.com/users/joshfree/repos","events_url":"https://api.github.com/users/joshfree/events{/privacy}","received_events_url":"https://api.github.com/users/joshfree/received_events","type":"User","site_admin":false},"open_issues":146,"closed_issues":281,"state":"open","created_at":"2015-10-20T04:29:15Z","updated_at":"2016-01-14T18:11:02Z","due_on":"2016-02-02T08:00:00Z","closed_at":null},"comments":3,"created_at":"2016-01-14T17:48:06Z","updated_at":"2016-01-14T19:09:48Z","closed_at":null,"body":"Filing on behalf of @dsaf from https://github.com/dotnet/coreclr/issues/2651:\r\n\r\n\r\nSteps to reproduce:\r\n\r\n1) Create a new PCL project targeting .NET 4.5, Win 8 and SL 5 (Profile47)\r\n2) Change ```Class1.cs``` to following code (notice it compiles):\r\n```csharp\r\n    public class Class1\r\n    {\r\n        private void Test()\r\n        {\r\n            IConvertible test;\r\n        }\r\n    }\r\n```\r\n3) Disable SL 5 target in project settings, notice a message *\"The following will be automatically targeted because they support the same set of portable APIs: ASP.NET Core 5.0\"*. Project changes to Profile7\r\n\r\n4) Compilation is now broken: *\"CS0246 The type or namespace name 'IConvertible' could not be found (are you missing a using directive or an assembly reference?)\"*\r\n\r\nThe code could be relying on value types inheriting ```IConvertible``` as well, so it needs the interface. There are likely to be other similar breaking changes around Reflection APIs.\r\n\r\nEffectively there seems to be a bug in some piece of code that tells that a set of portable APIs is common when in fact it is not. I don't know where it is: in PCL profile configuration, Visual Studio or .NET Framework.\r\n\r\nRemoving a target should not be a breaking change."},"comment":{"url":"https://api.github.com/repos/dotnet/corefx/issues/comments/171743685","html_url":"https://github.com/dotnet/corefx/issues/5422#issuecomment-171743685","issue_url":"https://api.github.com/repos/dotnet/corefx/issues/5422","id":171743685,"user":{"login":"Pilchie","id":312835,"avatar_url":"https://avatars.githubusercontent.com/u/312835?v=3","gravatar_id":"","url":"https://api.github.com/users/Pilchie","html_url":"https://github.com/Pilchie","followers_url":"https://api.github.com/users/Pilchie/followers","following_url":"https://api.github.com/users/Pilchie/following{/other_user}","gists_url":"https://api.github.com/users/Pilchie/gists{/gist_id}","starred_url":"https://api.github.com/users/Pilchie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Pilchie/subscriptions","organizations_url":"https://api.github.com/users/Pilchie/orgs","repos_url":"https://api.github.com/users/Pilchie/repos","events_url":"https://api.github.com/users/Pilchie/events{/privacy}","received_events_url":"https://api.github.com/users/Pilchie/received_events","type":"User","site_admin":false},"created_at":"2016-01-14T19:09:48Z","updated_at":"2016-01-14T19:09:48Z","body":"Wait, I take that back - this is from mscorlib portable -> system runtime portable, not system runtime portable -> nuget portable.\r\n\r\n@davkean says this is by design.  We had to keep `IConvertible` in mscorlib based portable due to dependencies from the VB compiler, but didn't carry it forward into system runtime."}}