description | title | ms.date | f1_keywords | helpviewer_keywords | ms.assetid | |||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Learn more about: Compiler errors C2100 through C2199 |
Compiler errors C2100 through C2199 |
04/21/2019 |
|
|
1ccab076-0954-4386-b959-d3112a6793ae |
The articles in this section of the documentation explain a subset of the error messages that are generated by the compiler.
[!INCLUDEerror-boilerplate]
Error | Message |
---|---|
Compiler error C2100 | illegal indirection |
Compiler error C2101 | '&' on constant |
Compiler error C2102 | '&' requires l-value |
Compiler error C2103 | '&' on register variable |
Compiler error C2104 | '&' on bit field ignored |
Compiler error C2105 | 'operator' needs l-value |
Compiler error C2106 | 'operator': left operand must be l-value |
Compiler error C2107 | illegal index, indirection not allowed |
Compiler error C2108 | subscript is not of integral type |
Compiler error C2109 | subscript requires array or pointer type |
Compiler error C2110 | '+': cannot add two pointers |
Compiler error C2111 | '+': pointer addition requires integral operand |
Compiler error C2112 | '-': pointer subtraction requires integral or pointer operand |
Compiler error C2113 | '-': pointer can only be subtracted from another pointer |
Compiler error C2114 | 'operator': pointer on left; needs integral value on right |
Compiler error C2115 | 'operator': incompatible types |
Compiler error C2116 | function parameter lists differed |
Compiler error C2117 | 'identifier': array bounds overflow |
Compiler error C2118 | negative subscript |
Compiler error C2119 | 'identifier': the type for 'type' cannot be deduced from an empty initializer |
Compiler error C2120 | 'void' illegal with all types |
Compiler error C2121 | '#': invalid character: possibly the result of a macro expansion |
Compiler error C2122 | 'identifier': prototype parameter in name list illegal |
Compiler error C2123 | 'identifier': alias templates cannot be explicitly or partially specialized |
Compiler error C2124 | divide or mod by zero |
Compiler error C2125 | 'constexpr' is incompatible with 'token' |
Compiler error C2126 | 'identifier' cannot be declared with 'constexpr' specifier |
Compiler error C2127 | 'identifier': illegal initialization of 'constexpr' entity with a non-constant expression |
Compiler error C2128 | 'function': alloc_text/same_seg applicable only to functions with C linkage |
Compiler error C2129 | static function 'identifier' declared but not defined |
Compiler error C2130 | #line expected a string containing the filename, found 'token' |
Compiler error C2131 | expression did not evaluate to a constant |
Compiler error C2132 | syntax error: unexpected identifier |
Compiler error C2133 | 'identifier': unknown size |
Compiler error C2134 | 'function': call does not result in a constant expression |
Compiler error C2135 | 'operator': illegal bit field operation |
Compiler error C2136 | authoring API contract not allowed |
Compiler error C2137 | empty character constant |
Compiler error C2138 | illegal to define an enumeration without any members |
Compiler error C2139 | 'class': an undefined class is not allowed as an argument to compiler intrinsic type trait 'trait' |
Compiler error C2140 | 'type': a type that is dependent on a generic type parameter is not allowed as an argument to compiler intrinsic type trait 'trait' |
Compiler error C2141 | array size overflow |
Compiler error C2142 | function declarations differ, variable parameters specified only in one of them |
Compiler error C2143 | syntax error: missing 'token1' before 'token2' |
Compiler error C2144 | syntax error: 'type' should be preceded by 'token2' |
Compiler error C2145 | syntax error: missing 'token' before identifier |
Compiler error C2146 | syntax error: missing 'token' before identifier 'identifier' |
Compiler error C2147 | syntax error: 'token' is a new keyword |
Compiler error C2148 | total size of array must not exceed 0xvalue bytes |
Compiler error C2149 | 'identifier': named bit field cannot have zero width |
Compiler error C2150 | 'identifier': bit field must have type 'int', 'signed int', or 'unsigned int' |
Compiler error C2151 | more than one language attribute |
Compiler error C2152 | 'identifier': pointers to functions with different attributes |
Compiler error C2153 | integer literals must have at least one digit |
Compiler error C2154 | 'type': only enumeration type is allowed as an argument to compiler intrinsic type trait 'trait' |
Compiler error C2155 | '?': invalid left operand, expected arithmetic or pointer type |
Compiler error C2156 | pragma must be outside function |
Compiler error C2157 | 'identifier': must be declared before use in pragma list |
Compiler error C2158 | 'type': #pragma make_public directive is currently supported for native non-template types only |
Compiler error C2159 | more than one storage class specified |
Compiler error C2160 | '##' cannot occur at the beginning of a macro definition |
Compiler error C2161 | '##' cannot occur at the end of a macro definition |
Compiler error C2162 | expected macro formal parameter |
Compiler error C2163 | 'function': not available as an intrinsic function |
Compiler error C2164 | 'function': intrinsic function not declared |
Compiler error C2165 | 'modifier': cannot modify pointers to data |
Compiler error C2166 | l-value specifies const object |
Compiler error C2167 | 'function': too many actual parameters for intrinsic function |
Compiler error C2168 | 'function': too few actual parameters for intrinsic function |
Compiler error C2169 | 'function': intrinsic function, cannot be defined |
Compiler error C2170 | 'identifier': not declared as a function, cannot be intrinsic |
Compiler error C2171 | 'operator': illegal on operands of type 'type' |
Compiler error C2172 | 'function': actual parameter is not a pointer: parameter number |
Compiler error C2173 | 'function': actual parameter is not a pointer: parameter number, parameter list number |
Compiler error C2174 | 'function': actual parameter has type 'void': parameter number, parameter list number |
Compiler error C2175 | 'locale': invalid locale |
Compiler error C2176 | a return statement cannot appear in the handler of a function-try-block associated with a constructor |
Compiler error C2177 | constant too big |
Compiler error C2178 | 'identifier' cannot be declared with 'specifier' specifier |
Compiler error C2179 | 'type': an attribute argument cannot use type parameters |
Compiler error C2180 | controlling expression has type 'type' |
Compiler error C2181 | illegal else without matching if |
Compiler error C2182 | 'identifier': illegal use of type 'void' |
Compiler error C2183 | syntax error: translation unit is empty |
Compiler error C2184 | 'type': illegal type for __except expression |
Compiler error C2185 | 'identifier': illegal based allocation |
Compiler error C2186 | 'operator': illegal operand of type 'void' |
Compiler error C2187 | syntax error: 'token' was unexpected here |
Compiler error C2188 | 'number': too big for wide character |
Compiler error C2189 | 'alignas' attribute cannot be applied to a bit-field, a function parameter, an exception declaration, or a variable declared with 'register' storage class |
Compiler error C2190 | first parameter list longer than second |
Compiler error C2191 | second parameter list longer than first |
Compiler error C2192 | parameter 'number' declaration different |
Compiler error C2193 | 'identifier': already in a segment |
Compiler error C2194 | 'identifier': is a text segment |
Compiler error C2195 | 'identifier': is a data segment |
Compiler error C2196 | case value 'value' already used |
Compiler error C2197 | 'function': too many arguments for call |
Compiler error C2198 | 'function': too few arguments for call |
Compiler error C2199 | syntax error: found 'identifier (' at global scope (was a declaration intended?) |
C/C++ Compiler and build tools errors and warnings
Compiler errors C2001 - C3999, C7000 - C7999