variant icon indicating copy to clipboard operation
variant copied to clipboard

C++11/C++14 Variant

Results 34 variant issues
Sort by recently updated
recently updated
newest added

In the current code there is no implementation for `swap()` which means `std::swap()` will be used. This should do the right thing (as long as the move constructor and move...

enhancement

Hashing a variant should take the type index / `.which()` into account in addition to the underlying hash - https://github.com/mapbox/variant/blob/02bd1ac4c07e6db9fe0f01267853e43b41637b74/include/mapbox/variant.hpp#L1002-L1011 - https://github.com/mapbox/variant/blob/02bd1ac4c07e6db9fe0f01267853e43b41637b74/include/mapbox/variant.hpp#L536-L544 Why? Because of the edge case where the...

enhancement

For https://github.com/mapbox/variant/issues/104 - cc @artemp @jfirebaugh In a future version we want to remove the `mapbox::util::` namespace. Until then we provide both adding a deprecation warning to the readme. Implementation...

While working on https://github.com/mapbox/variant/pull/126 I tested what happens if `Ts` are not Hashable. Turns out the error messages are pretty bad - as expected. This is true for all features...

enhancement

I'm creating this separate issue to keep the discussion in #113 clean. > @artemp Because variant::visit doesn't modify internal state and making it static gives compiler some hints on how...

Dear Mapbox Variant authors, I would like to contribute support headers for Boost.Spirit.Qi and Karma to mapbox::variant, so that usage of Mapbox::variant with Qi and Karma get really easy. ##...

The extra level `util` namespace is unnecessary: we're not going to have a conflict on the name `variant` in the `mapbox` namespace, and `util` does not add any semantic information;...

interface change

If called on uninitialized variant, `apply_visitor` leads to dispatcher calling `get` with the last alternative type, which throws. This PR changes the behaviour so that the dispatcher either - throws...

You can check how the test ran on master here: https://travis-ci.org/lightmare/variant/builds/106630852 With this patch Travis/AppVeyor will still fail, that's intended. Except for Xcode6 having some issue with `is_nothrow_move_constructible`, all other...

I think the `noexcept` on `operator()` [here](https://github.com/mapbox/variant/blob/c4e864cc122c4fcc9b1f7a8f68a34e465df9f922/variant.hpp#L644) is wrong. There are several operations involved which all might fail.