Code:
#include <iostream>
#include <vector>
int main ()
{
std::vector<int> numbers(10);
int32_t t1 = -1;
uint32_t t2 = numbers.size();
std::cout << (t1 < t2 ? "yes" : "no") << std::endl; // Warning
std::cout << ((signed)-1 < (unsigned)2); // No warning
return 0;
}
/* my output
no
0
*/
main.cpp
****** {BD Software Proxy c++ v3.43a for gcc} STL Message Decryption is Off ******
main.cpp: In function `int main()':
main.cpp:9: warning: comparison between signed and unsigned integer expressions
main.cpp:10: warning: comparison between signed and unsigned integer expressions