Registry / utility / boost-variant

boost-variant

JSON →
library1.90.0vcpkgunverified

Boost.Variant provides a type-safe union for storing one of several types.

vcpkg install boost-variant
INSTALL
IMPORT
SIG · BOOST-VARIANT
B
boost-variant
utilitycppv1.90.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

boost/variant.hpp
#include <boost/variant.hpp>

Create and print a variant holding a string

#include <boost/variant.hpp> #include <iostream> int main() { boost::variant<int, std::string> v = "hello"; std::cout << v << std::endl; return 0; }
Debug
Known issues
breakingBoost.Variant is deprecated in favor of std::variant (C++17) or Boost.Variant2.
fix
Use std::variant if targeting C++17 or later; otherwise consider Boost.Variant2.
affects: >=1.80.0
Upgrade
Version history
1.90.0latest on vcpkg
Audit
Dependencies

No dependency data recorded yet.

Agent activity
5 hits · last 30 days
node
4
Amazon
1
Resources

No resource links recorded.

boost-variant — pip install boost-variant · libregistry