Napomena
Pristup ovoj stranici zahtijeva autorizaciju. Možete pokušati prijaviti se ili promijeniti direktorije.
Pristup ovoj stranici zahtijeva autorizaciju. Možeš pokušati promijeniti direktorije.
Variable 'variable' is uninitialized. Always initialize an object.
Remarks
This check requires local variables to be initialized at the declaration or in the following statement.
Example
#include <iostream>
void function()
{
int myVal; // C26494, Variable is uninitialized
std::cout << myVal; // C6001
}
To fix the issue, initialize the variable at the declaration.
#include <iostream>
void function()
{
int myVal{};
std::cout << myVal;
}
See also
ES.20: Always initialize an object
Pro.safety: Type-safety profile