Quantcast
Channel: Intel® C++ Compiler
Viewing all articles
Browse latest Browse all 1616

A member with in-class initializer must be const. What?

$
0
0

I have explicitly enabled C++0x support in my project (latest C++ composer version) and I'm getting the above error. What is going on? The code I'm using is

static bimap<string, Type> typeNames = createTypeNames();

It doesn't seem like this works, and neither does inline initialization (i.e., typeNames = { { "Foo", Type::abc }}).


Viewing all articles
Browse latest Browse all 1616

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>