Please fill also the fields below. Note that root -b -q will tell you this info, and starting from 6.28/06 upwards, you can call .forum bug from the ROOT prompt to pre-populate a topic.
ROOT Version: 6.28 Platform: windows 10 Compiler: visual studio community 2022 C++
I run the df014_CSVDataSource.C File Reference in visual studio, find a error and I need help to solve it。please see the attachments.
Do you have any warning when building your application? Like for example:
The C++ standard in this build does not match ROOT configuration (201703L); this might cause unexpected issues. And please make sure you are using the -Zc:__cplusplus compilation flag
Because I don’t understand why you have these lines:
if (CMAKE_VERSION VERSION_GREATER 3.12)
set_property(TARGET e3 PROPERTY CXX_STANDARD 20)
endif()
I.e. I don’t see how the C++ standard depends on the CMake version… You must use the same standard than ROOT itself (c++17)
No such warning when building.
I have change c++20 to c++17, the problem is also being.
if (CMAKE_VERSION VERSION_GREATER 3.12)
set_property(TARGET e3 PROPERTY CXX_STANDARD 17)
endif()