{"action":"created","issue":{"url":"https://api.github.com/repos/manastech/crystal_lib/issues/9","labels_url":"https://api.github.com/repos/manastech/crystal_lib/issues/9/labels{/name}","comments_url":"https://api.github.com/repos/manastech/crystal_lib/issues/9/comments","events_url":"https://api.github.com/repos/manastech/crystal_lib/issues/9/events","html_url":"https://github.com/manastech/crystal_lib/issues/9","id":116018249,"number":9,"title":"Generated code fails to compile due to including multiple definitions of a data structure.","user":{"login":"samis","id":430108,"avatar_url":"https://avatars.githubusercontent.com/u/430108?v=3","gravatar_id":"","url":"https://api.github.com/users/samis","html_url":"https://github.com/samis","followers_url":"https://api.github.com/users/samis/followers","following_url":"https://api.github.com/users/samis/following{/other_user}","gists_url":"https://api.github.com/users/samis/gists{/gist_id}","starred_url":"https://api.github.com/users/samis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/samis/subscriptions","organizations_url":"https://api.github.com/users/samis/orgs","repos_url":"https://api.github.com/users/samis/repos","events_url":"https://api.github.com/users/samis/events{/privacy}","received_events_url":"https://api.github.com/users/samis/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-10T03:31:49Z","updated_at":"2015-11-10T15:49:28Z","closed_at":null,"body":"(I had difficulty coming up with a good title for this.) Since #8 was fixed, the tool can now successfully parse and generate code for Eina.h which is excellent. The generated code even almost compiles without manual intervention :grinning:. However, there is one issue with the generated code: It defines the struct `X___Data` twice, causing it to fail to compile. The two definitions start [here](https://gist.github.com/samis/b4e30e7333dda83de08e#file-lib_eina-cr-L1189) and [here](https://gist.github.com/samis/b4e30e7333dda83de08e#file-lib_eina-cr-L1216) respectively."},"comment":{"url":"https://api.github.com/repos/manastech/crystal_lib/issues/comments/155459598","html_url":"https://github.com/manastech/crystal_lib/issues/9#issuecomment-155459598","issue_url":"https://api.github.com/repos/manastech/crystal_lib/issues/9","id":155459598,"user":{"login":"asterite","id":209371,"avatar_url":"https://avatars.githubusercontent.com/u/209371?v=3","gravatar_id":"","url":"https://api.github.com/users/asterite","html_url":"https://github.com/asterite","followers_url":"https://api.github.com/users/asterite/followers","following_url":"https://api.github.com/users/asterite/following{/other_user}","gists_url":"https://api.github.com/users/asterite/gists{/gist_id}","starred_url":"https://api.github.com/users/asterite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asterite/subscriptions","organizations_url":"https://api.github.com/users/asterite/orgs","repos_url":"https://api.github.com/users/asterite/repos","events_url":"https://api.github.com/users/asterite/events{/privacy}","received_events_url":"https://api.github.com/users/asterite/received_events","type":"User","site_admin":false},"created_at":"2015-11-10T15:49:28Z","updated_at":"2015-11-10T15:49:28Z","body":"@samis I'm not getting that definition. I use:\r\n\r\n```crystal\r\n@[Include(\"stdarg.h\", \"eina/Eina.h\", flags: \"-I/Users/asterite-manas/Sandbox/efl/src/lib\", prefix: %w(eina_))]\r\n@[Link(\"eina\")]\r\nlib LibEina\r\nend\r\n```\r\n\r\nMaybe I need to include more `.h` files? What `Include` are you using?"}}