Click here to Skip to main content
15,848,724 members

Comments by Orjan Westin (Top 41 by date)

Orjan Westin 10-May-18 3:47am View    
No, the integer members emp_id and bps should be initialised.
Orjan Westin 8-May-18 10:46am View    
No need to initialise the string members - they are already "". To say they MUST be set is misleading.
Orjan Westin 2-Jul-15 6:42am View    
You can put your class template function definition in a CPP file if you:
a) declare one or more instances of the class in the same file, and
b) you will only need those specific types.

In this case, any use of those specific types, in any other source file, will be found by the linker, so you won't get any complaints. This is quite useful for traits-based design.
Orjan Westin 21-Jan-15 5:35am View    
Thank you. :)
Orjan Westin 12-Dec-14 4:49am View    
No, a short is never bigger than an int and never smaller than a char, and a long is never smaller than an int. That's all the language specifies. On 16-bit architectures (showing my age here) short was often 8 bits.