Здравствуйте, Sergeant, Вы писали:
S>Здравствуйте, Red Line, Вы писали:
RL>>Проект делал другой человек в VS 6.0 RL>>Переслал его мне. Что дальше — см. выше... RL>>Я конечно могу просидеть 1 час и задать начальные значения для каждой переменной, RL>>но я так думаю что есть способ решить эту проблему проще... Или как это можно выключить? RL>>Где это можно выключить в MS VS NET 2003.? RL>>Заранее благодарен всем!
S>Выключить в настройках проекта Warnings as errors, или как-то так.
/RTCu Reports when a variable is used without having been initialized. For example, an instruction that generates C4701 may also generate a run-time error under /RTCu. Any instruction that generates C4700 will generate a run-time error under /RTCu.
However, consider the following code fragment:
int a, *b, c;
if ( 1 )
b = &a;
c = a; // no run-time error with /RTCu
If a variable could have been initialized, it will not be reported at run time by /RTCu. For example, after a variable is aliased through a pointer, the compiler will not track the variable and report uninitialized uses. In effect, you can initialize a variable by taking its address. The & operator works like an assignment operator in this situation.
----------------------------------------------------------------------