Notiz
Zougrëff op dës Säit erfuerdert Autorisatioun. Dir kënnt probéieren, Iech unzemellen oder Verzeechnesser ze änneren.
Zougrëff op dës Säit erfuerdert Autorisatioun. Dir kënnt probéieren, Verzeechnesser ze änneren.
'specifier': an iteration variable cannot have any storage-class specifiers
Remarks
A storage class can't be specified on an iteration variable. For more information, see Storage classes (C++) and for each, in.
Example
The following example generates C3286, and also shows correct usage.
// C3286.cpp
// compile with: /clr
int main() {
array<int> ^p = { 1, 2, 3 };
for each (static int i in p) {} // C3286
for each (int j in p) {} // OK
}