Boost logo

Boost Users :

Subject: Re: [Boost-users] [ICL] Can't use an enum as map value
From: Oodini (svdbg____at_[hidden])
Date: 2014-03-19 09:12:08

> That's run-time knowledge that the compiler can't infer or use.
> Investigate whether it's possible to avoid this behaviour via some
> policy

Probably, but the documentation is not very clear about the policies.

> or if it might be acceptable to have a bogus operator+= defined
> for your type somewhere where it can be found.

By using the insert() method, instead of add(), I can get what I wanted (see the other thred I initiated), because the insert() method isn't annoyed by the enum type.

> If none of those are acceptable, you could always consider patching
> the library to provide such a policy or trait.

I'd like to, but I dont' think my employer will agree... (time is money !).

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at