Compiler Error C2117
Visual Studio 2015
The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.
The latest version of this topic can be found at Compiler Error C2117.
identifier' : array bounds overflow
An array has too many initializers:
Array elements and initializers do not match in size and quantity.
No space for the null terminator in a string.
The following sample generates C2117:
// C2117.cpp
int main() {
char abc[4] = "abcd"; // C2117
char def[4] = "abd"; // OK
}
Show: