{"action":"opened","issue":{"url":"https://api.github.com/repos/sandstorm-io/capnproto/issues/377","repository_url":"https://api.github.com/repos/sandstorm-io/capnproto","labels_url":"https://api.github.com/repos/sandstorm-io/capnproto/issues/377/labels{/name}","comments_url":"https://api.github.com/repos/sandstorm-io/capnproto/issues/377/comments","events_url":"https://api.github.com/repos/sandstorm-io/capnproto/issues/377/events","html_url":"https://github.com/sandstorm-io/capnproto/issues/377","id":181095778,"number":377,"title":"Cannot use nested structs in union","user":{"login":"ThomasBrixLarsen","id":7152480,"avatar_url":"https://avatars.githubusercontent.com/u/7152480?v=3","gravatar_id":"","url":"https://api.github.com/users/ThomasBrixLarsen","html_url":"https://github.com/ThomasBrixLarsen","followers_url":"https://api.github.com/users/ThomasBrixLarsen/followers","following_url":"https://api.github.com/users/ThomasBrixLarsen/following{/other_user}","gists_url":"https://api.github.com/users/ThomasBrixLarsen/gists{/gist_id}","starred_url":"https://api.github.com/users/ThomasBrixLarsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ThomasBrixLarsen/subscriptions","organizations_url":"https://api.github.com/users/ThomasBrixLarsen/orgs","repos_url":"https://api.github.com/users/ThomasBrixLarsen/repos","events_url":"https://api.github.com/users/ThomasBrixLarsen/events{/privacy}","received_events_url":"https://api.github.com/users/ThomasBrixLarsen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-10-05T08:43:03Z","updated_at":"2016-10-05T08:43:03Z","closed_at":null,"body":"I have compiled using commit 634c040175b4528b6b60685da4ff97d7bc3fe3f5.\r\n\r\ngcc-version 6.2.1 20160830 (GCC)\r\n\r\n**Test case**\r\n```\r\n@0xf5f9f8fe0c2ad887;\r\n\r\nstruct Outer {\r\n\tunion {\r\n\t\talpha @0 :Alpha;\r\n\t\tbravo @1 :Bravo;\r\n\t}\r\n\t\r\n\tstruct Alpha {\r\n\t\tcharlie @0 :Void;\r\n\t\tdelta @1 :Void;\r\n\t}\r\n\tstruct Bravo {\r\n\t\techo @0 :Void;\r\n\t\tfoxtrot @1 :Void;\r\n\t}\r\n}\r\n```\r\n\r\n**Error example**\r\n```\r\nIn file included from testcase.capnp.c++:4:0:\r\ntestcase.capnp.h:138:57: error: type/value mismatch at argument 1 in template parameter list for 'template<class T> class capnp::Orphan'\r\n   inline void adoptAlpha(::capnp::Orphan< ::Outer::Alpha>&& value);\r\n                                                         ^\r\ntestcase.capnp.h:138:57: note:   expected a type, got 'Alpha'\r\ntestcase.capnp.h:139:41: error: type/value mismatch at argument 1 in template parameter list for 'template<class T> class capnp::Orphan'\r\n   inline ::capnp::Orphan< ::Outer::Alpha> disownAlpha();\r\n                                         ^\r\ntestcase.capnp.h:139:41: note:   expected a type, got 'Alpha'\r\ntestcase.capnp.h:146:57: error: type/value mismatch at argument 1 in template parameter list for 'template<class T> class capnp::Orphan'\r\n   inline void adoptBravo(::capnp::Orphan< ::Outer::Bravo>&& value);\r\n                                                         ^\r\ntestcase.capnp.h:146:57: note:   expected a type, got 'Bravo'\r\ntestcase.capnp.h:147:41: error: type/value mismatch at argument 1 in template parameter list for 'template<class T> class capnp::Orphan'\r\n   inline ::capnp::Orphan< ::Outer::Bravo> disownBravo();\r\n```\r\nThere are more similar errors following."}}
{"actor":{"display_login":"ThomasBrixLarsen"}}