Standard behavior for direct initialization of unsigned short
问题 I noticed today that in the example code: void print(unsigned short a) { std::cout << a << std::endl; } Initialization and use works like this: print(short (5)); But not like this: print(unsigned short(6)); main.cpp:16:8: error: expected primary-expression before 'unsigned' print(unsigned short(6)); And it's not to do with the type since this also works: typedef unsigned short ushort; print(ushort (6)); Live example. So I went searching for what the standard says about value initialization.