USNavalResearchLaboratory / cxxplot

A simple to use C++ 2D plotting library.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

error: no matching function for call to object of type 'const __transform::__fn' ; no member named 'filter' in namespace 'std::ranges::views'

yurivict opened this issue · comments

/disk-samsung/freebsd-ports/graphics/cxxplot/work/cxxplot-0.3.0-2-g750b54b/examples/06_ranges/main.cpp:22:9: error: no matching function for call to object of type 'const __transform::__fn'
        views::transform( sin );
        ^~~~~~~~~~~~~~~~
/usr/include/c++/v1/__ranges/transform_view.h:423:20: note: candidate template ignored: couldn't infer template argument '_Fn'
    constexpr auto operator()(_Fn&& __f) const
                   ^
/usr/include/c++/v1/__ranges/transform_view.h:415:20: note: candidate function template not viable: requires 2 arguments, but 1 was provided
    constexpr auto operator()(_Range&& __range, _Fn&& __f) const
                   ^
/disk-samsung/freebsd-ports/graphics/cxxplot/work/cxxplot-0.3.0-2-g750b54b/examples/06_ranges/main.cpp:26:16: error: no member named 'filter' in namespace 'std::ranges::views'
        views::filter( []( auto v ) { return std::abs( v ) < 0.9; } );
        ~~~~~~~^
2 errors generated.

clang-14
FreeBSD 13.1

Thank you. Clang-14 probably has incomplete ranges implementation, and we are not testing against it. Pushed a commit (4fa696d) to address unsupported compilers but will leave the issue open to revisit when ranges support appears complete.

If it is still not compiling, it would be appreciated if you could report back.

Should have been fixed now. If this is still an issue, please comment and report back.