Category : ambiguous-call

Given the code #include <boost/hana/transform.hpp> #include <range/v3/view/transform.hpp> #include <vector> using namespace boost::hana; using namespace ranges::views; int main(){ std::vector<int> v{}; auto constexpr one = [](auto const&){ return 1; }; auto w = v | transform(one); } the error is Reference to ‘transform’ is ambiguous. I know I’ve brought both transforms in scope via using directives, but ..

Read more

I cannot figure out why I am getting the error "reference to ‘distance’ is ambiguous". I have passed class object as an argument in friend function. #include <iostream> using namespace std; class distance { int meters = 0; public: distance() {} void displaydata() { cout << "Meters Value:" << meters; } //Prototype friend void addvalue(distance ..

Read more