В пятнадцатом шланге появился флаг unqualified-std-cast-call включённый по умолчанию и теперь то что раньше собиралось, падает с вклюённым по умолчанию -Werror,-Wunqualified-std-cast-call
.
Вопрос, что это такое и как его лечить, т.к. я походу совсем потерялся в современных плюсах с его темплейтами.
Вот на какой код ругается:
template<typename... types_t>
error call(
rsComm_t* _comm,
const std::string& _operation_name,
irods::first_class_object_ptr _fco,
types_t... _t)
{
using namespace std;
...
return adapted_fcn( ctx, &out_param, forward<types_t>(_t)... ); // << error: unqualified call to 'std::forward'
Где
using adapted_func_type = std::function<error(plugin_context&, std::string*, types_t...)>;
adapted_func_type adapted_fcn = [this, &_operation_name](plugin_context& _ctx, std::string* _out_param, types_t... _t) {
Падает всё сообщением:
In file included from /var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/src/clientLogin.cpp:6:
In file included from /var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/include/irods_auth_plugin.hpp:5:
In file included from /var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/include/irods_auth_types.hpp:9:
/var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/include/irods_plugin_base.hpp:284:54: error: unqualified call to 'std::forward' [-Werror,-Wunqualified-std-cast-call]
return adapted_fcn( ctx, &out_param, forward<types_t>(_t)... );
^
std::
/var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/src/clientLogin.cpp:284:24: note: in instantiation of function template specialization 'irods::plugin_base::call<RcComm *, const char *>' requested here
ret = auth_plugin->call <rcComm_t*, const char* > ( NULL, irods::AUTH_CLIENT_START, auth_obj, _comm, _context );
^
In file included from /var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/src/clientLogin.cpp:6:
In file included from /var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/include/irods_auth_plugin.hpp:5:
In file included from /var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/include/irods_auth_types.hpp:9:
/var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/include/irods_plugin_base.hpp:284:54: error: unqualified call to 'std::forward' [-Werror,-Wunqualified-std-cast-call]
return adapted_fcn( ctx, &out_param, forward<types_t>(_t)... );
^
std::
/var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/include/irods_plugin_base.hpp:284:54: error: unqualified call to 'std::forward' [-Werror,-Wunqualified-std-cast-call]
return adapted_fcn( ctx, &out_param, forward<types_t>(_t)... );
^
std::
/var/calculate/tmp/portage/net-misc/irods-4.2.11-r6/work/irods-4.2.11/lib/core/src/clientLogin.cpp:292:24: note: in instantiation of function template specialization 'irods::plugin_base::call<RcComm *>' requested here
ret = auth_plugin->call <rcComm_t* > ( NULL, irods::AUTH_CLIENT_AUTH_REQUEST, auth_obj, _comm );
^
3 errors generated.