WFPExplorer icon indicating copy to clipboard operation
WFPExplorer copied to clipboard

Compile error in "NewSubLayerDlg.cpp"

Open gvanem opened this issue 9 months ago • 0 comments

Compiling NewSubLayerDlg.cpp yields this errors:

WFPExplorer/NewSubLayerDlg.cpp(72): error C3861: 'to': identifier not found

and a huge list of other (related?) errors:

WFPExplorer/NewSubLayerDlg.cpp(66): error C2678: binary '|': no operator found which takes a left-hand operand of type 'std::ranges::transform_view<std::ranges::ref_view<WFPObjectVector<TItem,TItem *>>,CNewSubLayerDlg::OnInitDialog::<lambda_1>>'
(or there is no acceptable conversion)
        with
        [
            TItem=FWPM_PROVIDER0
        ]
f:\gv\VC_2022\VC\Tools\MSVC\14.44.34823\include\xfilesystem_abi.h(246): note: could be '__std_fs_copy_options operator |(__std_fs_copy_options,__std_fs_copy_options) noexcept'
WFPExplorer/NewSubLayerDlg.cpp(66): note: '__std_fs_copy_options operator |(__std_fs_copy_options,__std_fs_copy_options) noexcept': cannot convert argument 1 from 'std::ranges::tra
nsform_view<std::ranges::ref_view<WFPObjectVector<TItem,TItem *>>,CNewSubLayerDlg::OnInitDialog::<lambda_1>>' to '__std_fs_copy_options'
        with
        [
            TItem=FWPM_PROVIDER0
        ]
...

With clang-cl the error is clearly:

WFPExplorer/NewSubLayerDlg.cpp(72,9): error: use of undeclared identifier 'to'
   72 |                         }) | to<vector>();
      |                              ^
1 error generated.

What is to here?

Similar error in WFPExplorer/NewFilterDlg.cpp.

I'm on Win-10 using MSVC ver. 19.44.34823.2 for x64

gvanem avatar Mar 18 '25 07:03 gvanem