I can't see what is wrong here. The first line works fine. The second results in a compilation error "invalid initializer". I'm testing to see whether the first character in a string variable (init_value) is a '-' (ASCII value 45).
1 2
cout << int(init_value[0]) << endl;
if (int(init_value[0]) = 45)