The bug can be found here: http://llvm.org/bugs/show_bug.cgi?id=22468
__invoke_void_return_wrapper is needed to properly handle calling a function that returns a value but where the std::function return type is void. Without this '-Wsystem-headers' will cause function::operator()(...) to not compile.
While you're here, can you wrap this test in an #if __cplusplus >= 201103L so that this test will pass on C++03?
No std::bind in '03