{"action":"created","issue":{"url":"https://api.github.com/repos/keean/zenscript/issues/8","repository_url":"https://api.github.com/repos/keean/zenscript","labels_url":"https://api.github.com/repos/keean/zenscript/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/keean/zenscript/issues/8/comments","events_url":"https://api.github.com/repos/keean/zenscript/issues/8/events","html_url":"https://github.com/keean/zenscript/issues/8","id":178442049,"number":8,"title":"Subtyping","user":{"login":"shelby3","id":247731,"avatar_url":"https://avatars.githubusercontent.com/u/247731?v=3","gravatar_id":"","url":"https://api.github.com/users/shelby3","html_url":"https://github.com/shelby3","followers_url":"https://api.github.com/users/shelby3/followers","following_url":"https://api.github.com/users/shelby3/following{/other_user}","gists_url":"https://api.github.com/users/shelby3/gists{/gist_id}","starred_url":"https://api.github.com/users/shelby3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shelby3/subscriptions","organizations_url":"https://api.github.com/users/shelby3/orgs","repos_url":"https://api.github.com/users/shelby3/repos","events_url":"https://api.github.com/users/shelby3/events{/privacy}","received_events_url":"https://api.github.com/users/shelby3/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/keean/zenscript/labels/Future%20Work","name":"Future Work","color":"fbca04"}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":297,"created_at":"2016-09-21T19:34:08Z","updated_at":"2016-10-14T08:47:54Z","closed_at":"2016-10-04T17:05:24Z","body":"Union types express a subtyping relationship, but I am unclear as to whether typeclasses (i.e. Rust's traits) do?\r\n\r\nIf a `trait B` extends another `trait A` and `B` reuses the implementations of `A`, can we assign a trait object that has a bound `B` to a trait object that has a bound `A`?\r\n\r\nSeems the answer based on prior discussion is yes. But that is a subtyping relationship, which means we would need to deal with covariance on type parameters both when they are trait objects and when they are unions. Correct?\r\n\r\nPrior discussion:\r\nhttps://github.com/keean/zenscript/issues/6#issuecomment-248711828\r\nhttps://github.com/keean/zenscript/issues/1#issuecomment-248113585\r\nhttps://github.com/keean/traitscript/issues/2#issuecomment-248021713\r\nhttps://github.com/keean/zenscript/issues/1#issuecomment-248754649"},"comment":{"url":"https://api.github.com/repos/keean/zenscript/issues/comments/253743800","html_url":"https://github.com/keean/zenscript/issues/8#issuecomment-253743800","issue_url":"https://api.github.com/repos/keean/zenscript/issues/8","id":253743800,"user":{"login":"keean","id":508384,"avatar_url":"https://avatars.githubusercontent.com/u/508384?v=3","gravatar_id":"","url":"https://api.github.com/users/keean","html_url":"https://github.com/keean","followers_url":"https://api.github.com/users/keean/followers","following_url":"https://api.github.com/users/keean/following{/other_user}","gists_url":"https://api.github.com/users/keean/gists{/gist_id}","starred_url":"https://api.github.com/users/keean/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keean/subscriptions","organizations_url":"https://api.github.com/users/keean/orgs","repos_url":"https://api.github.com/users/keean/repos","events_url":"https://api.github.com/users/keean/events{/privacy}","received_events_url":"https://api.github.com/users/keean/received_events","type":"User","site_admin":false},"created_at":"2016-10-14T08:47:54Z","updated_at":"2016-10-14T08:47:54Z","body":"> Variance is only relevant in a system with subtyping, AFAICT\r\n\r\nYes this is my understanding as well.\r\n\r\nThis leaves me with the tricky problem of if/how to simplify unions."}}
{"actor":{"display_login":"keean"}}