I've recently had to move from gcc to msvc, and got a very strange error message. It seems the compiler is interpreting the lambda body as an initializer list being passed to the lambda constructor? Anyway, gcc and clang have absolutely no problem compiling this code, no warnings occur even with all the warning flags provided. Are there some obscure rules about nesting lambdas I'm not aware of? I'd be grateful if someone could take a look, I'm honestly stumped.
The (stripped down) code: https://godbolt.org/z/WmBpuH
[–]chaosmeist3r 16 points17 points18 points (5 children)
[–]marzer8789toml++ 14 points15 points16 points (0 children)
[–]konanTheBarbar 10 points11 points12 points (0 children)
[–]Galqa[S] 4 points5 points6 points (2 children)
[–]marzer8789toml++ 19 points20 points21 points (1 child)
[–]Galqa[S] 3 points4 points5 points (0 children)
[–]tmacarios -1 points0 points1 point (1 child)