ldalessa:~/temp$ cat test.cpp #include <atomic> struct Foo { Foo() : foo_() { } std::atomic<int> foo_[2]; }; int main() { } ldalessa:~/temp$ gcc --version gcc (GCC) 4.9.2 Copyright (C) 2014 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ldalessa:~/temp$ gcc -std=c++11 test.cpp ldalessa:~/temp$ icpc --version icpc (ICC) 15.0.4 20150805 Copyright (C) 1985-2015 Intel Corporation. All rights reserved. ldalessa: ~/temp$ icpc -std=c++11 test.cpp test.cpp(4): internal error: assertion failed at: "shared/cfe/edgcpfe/decl_inits.c", line 6224 Foo() : foo_() { } ^ compilation aborted for test.cpp (code 4)
Current workaround is to skip the initializer for this member variable.
Thread Topic:
Bug Report