{"action":"created","issue":{"url":"https://api.github.com/repos/elm-lang/elm-compiler/issues/948","labels_url":"https://api.github.com/repos/elm-lang/elm-compiler/issues/948/labels{/name}","comments_url":"https://api.github.com/repos/elm-lang/elm-compiler/issues/948/comments","events_url":"https://api.github.com/repos/elm-lang/elm-compiler/issues/948/events","html_url":"https://github.com/elm-lang/elm-compiler/issues/948","id":82971703,"number":948,"title":"Disallow case statements on non-exported types","user":{"login":"mgold","id":1191970,"avatar_url":"https://avatars.githubusercontent.com/u/1191970?v=3","gravatar_id":"","url":"https://api.github.com/users/mgold","html_url":"https://github.com/mgold","followers_url":"https://api.github.com/users/mgold/followers","following_url":"https://api.github.com/users/mgold/following{/other_user}","gists_url":"https://api.github.com/users/mgold/gists{/gist_id}","starred_url":"https://api.github.com/users/mgold/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mgold/subscriptions","organizations_url":"https://api.github.com/users/mgold/orgs","repos_url":"https://api.github.com/users/mgold/repos","events_url":"https://api.github.com/users/mgold/events{/privacy}","received_events_url":"https://api.github.com/users/mgold/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":10,"created_at":"2015-05-31T02:12:11Z","updated_at":"2015-05-31T18:29:24Z","closed_at":"2015-05-31T18:29:24Z","body":"Minimal example, outputs `\"red\"` in 0.15 and master:\r\n\r\n````elm\r\nimport Graphics.Element exposing (show)\r\nimport Color exposing (..)\r\n\r\nmain = show <| case purple of\r\n  red -> \"red\"\r\n  purple -> \"purple\"\r\n  _ -> \"some other color\"\r\n  ````\r\n\r\nThe compiler rejects the qualified names with a somewhat mysterious `expecting upper case variable`. However, the union type representation of colors is not exported, which I think is why this program (1) should be invalid (2) erroneously always takes the first option. This becomes more of a problem for larger opaque types, like `Dict`s and things with a Native implementation.\r\n\r\nIt's not a regression and it's fairly obscure, but hopefully it can get fixed at some point. Until then, multi-way if and equality checks work fine."},"comment":{"url":"https://api.github.com/repos/elm-lang/elm-compiler/issues/comments/107232368","html_url":"https://github.com/elm-lang/elm-compiler/issues/948#issuecomment-107232368","issue_url":"https://api.github.com/repos/elm-lang/elm-compiler/issues/948","id":107232368,"user":{"login":"mgold","id":1191970,"avatar_url":"https://avatars.githubusercontent.com/u/1191970?v=3","gravatar_id":"","url":"https://api.github.com/users/mgold","html_url":"https://github.com/mgold","followers_url":"https://api.github.com/users/mgold/followers","following_url":"https://api.github.com/users/mgold/following{/other_user}","gists_url":"https://api.github.com/users/mgold/gists{/gist_id}","starred_url":"https://api.github.com/users/mgold/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mgold/subscriptions","organizations_url":"https://api.github.com/users/mgold/orgs","repos_url":"https://api.github.com/users/mgold/repos","events_url":"https://api.github.com/users/mgold/events{/privacy}","received_events_url":"https://api.github.com/users/mgold/received_events","type":"User","site_admin":false},"created_at":"2015-05-31T18:29:24Z","updated_at":"2015-05-31T18:29:24Z","body":"And I mentioned this on the list of warnings ticket. I think we're good here, thanks for your help."}}