{"action":"created","issue":{"url":"https://api.github.com/repos/rollbear/trompeloeil/issues/14","repository_url":"https://api.github.com/repos/rollbear/trompeloeil","labels_url":"https://api.github.com/repos/rollbear/trompeloeil/issues/14/labels{/name}","comments_url":"https://api.github.com/repos/rollbear/trompeloeil/issues/14/comments","events_url":"https://api.github.com/repos/rollbear/trompeloeil/issues/14/events","html_url":"https://github.com/rollbear/trompeloeil/issues/14","id":166429629,"number":14,"title":"Compile time vs runtime reporter","user":{"login":"rcdailey","id":1768054,"avatar_url":"https://avatars.githubusercontent.com/u/1768054?v=3","gravatar_id":"","url":"https://api.github.com/users/rcdailey","html_url":"https://github.com/rcdailey","followers_url":"https://api.github.com/users/rcdailey/followers","following_url":"https://api.github.com/users/rcdailey/following{/other_user}","gists_url":"https://api.github.com/users/rcdailey/gists{/gist_id}","starred_url":"https://api.github.com/users/rcdailey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rcdailey/subscriptions","organizations_url":"https://api.github.com/users/rcdailey/orgs","repos_url":"https://api.github.com/users/rcdailey/repos","events_url":"https://api.github.com/users/rcdailey/events{/privacy}","received_events_url":"https://api.github.com/users/rcdailey/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-07-19T20:37:55Z","updated_at":"2016-07-20T06:59:26Z","closed_at":null,"body":"Correct me if I'm wrong, but it seems like when utilizing multiple translation units in a single test executable, the runtime reporter (calling `set_reporter`) is more desirable since I can do the reporter setup in 1 translation unit. Whereas the compile time approach requires including the specialized reporter class in each translation unit along with trompeloeil itself."},"comment":{"url":"https://api.github.com/repos/rollbear/trompeloeil/issues/comments/233858301","html_url":"https://github.com/rollbear/trompeloeil/issues/14#issuecomment-233858301","issue_url":"https://api.github.com/repos/rollbear/trompeloeil/issues/14","id":233858301,"user":{"login":"rollbear","id":9164980,"avatar_url":"https://avatars.githubusercontent.com/u/9164980?v=3","gravatar_id":"","url":"https://api.github.com/users/rollbear","html_url":"https://github.com/rollbear","followers_url":"https://api.github.com/users/rollbear/followers","following_url":"https://api.github.com/users/rollbear/following{/other_user}","gists_url":"https://api.github.com/users/rollbear/gists{/gist_id}","starred_url":"https://api.github.com/users/rollbear/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rollbear/subscriptions","organizations_url":"https://api.github.com/users/rollbear/orgs","repos_url":"https://api.github.com/users/rollbear/repos","events_url":"https://api.github.com/users/rollbear/events{/privacy}","received_events_url":"https://api.github.com/users/rollbear/received_events","type":"User","site_admin":false},"created_at":"2016-07-20T06:59:26Z","updated_at":"2016-07-20T06:59:26Z","body":"I won't have access to a windows development machine until after the weekend, but if you have the time, would you please try this out and tell me how it works?\r\n\r\nIn all TUs but one, add the line:\r\n```Cpp\r\nextern template struct trompeloeil::reporter<trompeloeil::specialized>;\r\n```\r\nIn one TU, reformat the compile time specialization as:\r\n```Cpp\r\nnamespace trompeloeil\r\n{\r\n  template <>\r\n  void reporter<specialized>::send(severity s,\r\n                                   const char* file,\r\n                                   unsigned long line,\r\n                                   const char* msg)\r\n  {\r\n      ...\r\n  }\r\n}\r\n```\r\n\r\nThis works with clang++ (3.6 and later) and g++ (4.9 and later.)"}}
{"actor":{"display_login":"rollbear"}}