{"action":"created","issue":{"url":"https://api.github.com/repos/leanprover/lean/issues/1003","repository_url":"https://api.github.com/repos/leanprover/lean","labels_url":"https://api.github.com/repos/leanprover/lean/issues/1003/labels{/name}","comments_url":"https://api.github.com/repos/leanprover/lean/issues/1003/comments","events_url":"https://api.github.com/repos/leanprover/lean/issues/1003/events","html_url":"https://github.com/leanprover/lean/issues/1003","id":133797377,"number":1003,"title":"extending structures with types in fields","user":{"login":"fpvandoorn","id":7376012,"avatar_url":"https://avatars.githubusercontent.com/u/7376012?v=3","gravatar_id":"","url":"https://api.github.com/users/fpvandoorn","html_url":"https://github.com/fpvandoorn","followers_url":"https://api.github.com/users/fpvandoorn/followers","following_url":"https://api.github.com/users/fpvandoorn/following{/other_user}","gists_url":"https://api.github.com/users/fpvandoorn/gists{/gist_id}","starred_url":"https://api.github.com/users/fpvandoorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fpvandoorn/subscriptions","organizations_url":"https://api.github.com/users/fpvandoorn/orgs","repos_url":"https://api.github.com/users/fpvandoorn/repos","events_url":"https://api.github.com/users/fpvandoorn/events{/privacy}","received_events_url":"https://api.github.com/users/fpvandoorn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-02-15T19:28:31Z","updated_at":"2016-02-15T20:36:15Z","closed_at":null,"body":"I get a universe error when extending structures which have a type in a field. Example:\r\n```lean\r\n-- HoTT\r\nopen is_trunc\r\n\r\nstructure my_Pointed :=\r\n  (carrier : Type)\r\n  (point   : carrier)\r\n\r\nstructure my_hset :=\r\n  (carrier : Type)\r\n  (struct : is_trunc 0 carrier)\r\n\r\nstructure phset extends my_hset, my_Pointed\r\n```\r\n\r\nError:\r\n```\r\ntype mismatch at application\r\n  my_hset.mk (ptrunctype.carrier s)\r\nterm\r\n  ptrunctype.carrier s\r\nhas type\r\n  Type.{l_1}\r\nbut is expected to have type\r\n  Type.{l_2}\r\n```\r\n\r\n(the example works when you replace `Type` by `Type₀` twice)"},"comment":{"url":"https://api.github.com/repos/leanprover/lean/issues/comments/184381175","html_url":"https://github.com/leanprover/lean/issues/1003#issuecomment-184381175","issue_url":"https://api.github.com/repos/leanprover/lean/issues/1003","id":184381175,"user":{"login":"fpvandoorn","id":7376012,"avatar_url":"https://avatars.githubusercontent.com/u/7376012?v=3","gravatar_id":"","url":"https://api.github.com/users/fpvandoorn","html_url":"https://github.com/fpvandoorn","followers_url":"https://api.github.com/users/fpvandoorn/followers","following_url":"https://api.github.com/users/fpvandoorn/following{/other_user}","gists_url":"https://api.github.com/users/fpvandoorn/gists{/gist_id}","starred_url":"https://api.github.com/users/fpvandoorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fpvandoorn/subscriptions","organizations_url":"https://api.github.com/users/fpvandoorn/orgs","repos_url":"https://api.github.com/users/fpvandoorn/repos","events_url":"https://api.github.com/users/fpvandoorn/events{/privacy}","received_events_url":"https://api.github.com/users/fpvandoorn/received_events","type":"User","site_admin":false},"created_at":"2016-02-15T20:36:15Z","updated_at":"2016-02-15T20:36:15Z","body":"That is a nice workaround! Thanks."}}