I am trying to initialize a map of cards using C ++ 11. My compiler is VS 2013 Express.
unordered_map<EnumType, unordered_map<string, string>> substitutions = { { Record::BasementType, { { "0", "" }, { "1", "Slab or pier" }, { "2", "Crawl" } } }, { Record::BuildingStyle, { { "0", "" }, { "1", "Ranch" }, { "2", "Raised ranch" } } },
It compiles, but I get a breakpoint inside ntdll.dll. However, a simplified version of this code:
unordered_map<EnumType, unordered_map<string, string>> substitutions = { { Record::BasementType, { { "0", "" }, { "1", "Slab or pier" }, { "2", "Crawl" } } },
works correctly.
Why doesn't this work when I have more than one pair on my card? How to do it better?
c ++ c ++ 11 visual-studio-2013 stl
omikron
source share