Using boost::any

Hi all.
I want to use specific boost lib. type called boost::any . There is a limited boost library in of. , but not in it. How can I do this?
Thanks.

Eyüp.

did you try std::any using c++17 ?

1 Like

Hi dimitre.
If I use c++17 I am geting errors relateted filesystem namespace conflict. There is a issue named that “[MSVC][std:c++latest] openFrameworks failed to build on MSVC #6832” on github. My friend recommended to use another header only “any” type structure to me. I will try this
GitHub - mpark/variant: C++17 std::variant for C++11/14/17
and
GitHub - martinmoene/variant-lite: variant lite - A C++17-like variant, a type-safe union for C++98, C++11 and later in a single-file header-only library

Hey @findux , the nightly build is compatible with c++17.

1 Like

Hi TimChi . Thank you so much I didn’t know nightly build. First I will try this.

1 Like

Hey you might have to add a -std=c++17 flag to your project too. Just post if you have any problems.

Hi .
I downloaded of_v20220917_vs2017_release nightly build and I builded example project “3DModelLoaderExample” . The project was already setted as std:++17 . I haven’t tried what I want to do yet. But I will continue with this method and I will use std::any instead of boost::any .
Thanks you all.

2 Likes