{"action":"created","issue":{"url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/2960","labels_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/2960/labels{/name}","comments_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/2960/comments","events_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/2960/events","html_url":"https://github.com/Beep6581/RawTherapee/pull/2960","id":114457393,"number":2960,"title":"Add explicit type conversions to satisfy C++11 requirements.","user":{"login":"bobobo1618","id":707839,"avatar_url":"https://avatars.githubusercontent.com/u/707839?v=3","gravatar_id":"","url":"https://api.github.com/users/bobobo1618","html_url":"https://github.com/bobobo1618","followers_url":"https://api.github.com/users/bobobo1618/followers","following_url":"https://api.github.com/users/bobobo1618/following{/other_user}","gists_url":"https://api.github.com/users/bobobo1618/gists{/gist_id}","starred_url":"https://api.github.com/users/bobobo1618/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bobobo1618/subscriptions","organizations_url":"https://api.github.com/users/bobobo1618/orgs","repos_url":"https://api.github.com/users/bobobo1618/repos","events_url":"https://api.github.com/users/bobobo1618/events{/privacy}","received_events_url":"https://api.github.com/users/bobobo1618/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-11-01T09:13:51Z","updated_at":"2015-11-06T01:33:46Z","closed_at":"2015-11-05T22:32:21Z","pull_request":{"url":"https://api.github.com/repos/Beep6581/RawTherapee/pulls/2960","html_url":"https://github.com/Beep6581/RawTherapee/pull/2960","diff_url":"https://github.com/Beep6581/RawTherapee/pull/2960.diff","patch_url":"https://github.com/Beep6581/RawTherapee/pull/2960.patch"},"body":"C++11 isn't a fan of narrowing. Just used explicit casts on the few parts of the codebase that relied on it."},"comment":{"url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/comments/154257359","html_url":"https://github.com/Beep6581/RawTherapee/pull/2960#issuecomment-154257359","issue_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/2960","id":154257359,"user":{"login":"bobobo1618","id":707839,"avatar_url":"https://avatars.githubusercontent.com/u/707839?v=3","gravatar_id":"","url":"https://api.github.com/users/bobobo1618","html_url":"https://github.com/bobobo1618","followers_url":"https://api.github.com/users/bobobo1618/followers","following_url":"https://api.github.com/users/bobobo1618/following{/other_user}","gists_url":"https://api.github.com/users/bobobo1618/gists{/gist_id}","starred_url":"https://api.github.com/users/bobobo1618/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bobobo1618/subscriptions","organizations_url":"https://api.github.com/users/bobobo1618/orgs","repos_url":"https://api.github.com/users/bobobo1618/repos","events_url":"https://api.github.com/users/bobobo1618/events{/privacy}","received_events_url":"https://api.github.com/users/bobobo1618/received_events","type":"User","site_admin":false},"created_at":"2015-11-06T01:33:46Z","updated_at":"2015-11-06T01:33:46Z","body":"Could you elaborate a bit? This PR is about https://github.com/bobobo1618/RawTherapee/commit/b93c73007ca38c0d49c0a558328806ab7cff35da specifically.\r\n\r\nThe reason I did this is that `glibmm` 2.4 and `sigc++` 2.6.1 (a `glibmm` dependency) both use C++11 features in their header files. Without the `-std=c++1y` flag on compilation, RawTherapee fails to compile, at least using Clang (the following example is a small snippet):\r\n\r\n```\r\n/usr/local/Cellar/libsigc++/2.6.1/include/sigc++-2.0/sigc++/functors/slot.h:737:21: error: expected ';' at end of declaration list\r\n  slot3(slot3&& src) noexcept\r\n                    ^\r\n                    ;\r\n/usr/local/Cellar/libsigc++/2.6.1/include/sigc++-2.0/sigc++/functors/slot.h:835:14: warning: rvalue references are a C++11 extension [-Wc++11-extensions]\r\n  slot4(slot4&& src) noexcept\r\n```\r\n\r\nOn the other hand, C++11 doesn't allow implicit conversions, so RT fails to compile _with_ the `-std=c++1y` flag a well. This commit simply makes the conversions explicit so that RT is C++11 compatible.\r\n\r\nAll the \\*mm projects and `sigc++` [have moved to C++ 11](http://www.murrayc.com/permalink/2015/07/31/gtkmm-now-uses-c11/) so fixing these things seems necessary, if not now then at some point in the future. And it seems easier to change 15 lines of RawTherapee code than to try to port the RT dependencies."}}