I have a piece fo code that I need to modify to return the number of bytes in a smart array of type <char>. Anyone know how to do this? I don't use smart types (I think they are yucky), but I have to fix someone elses code on this one.
This is a discussion on size of <char> within the C++ Programming forums, part of the General Programming Boards category; I have a piece fo code that I need to modify to return the number of bytes in a smart ...
I have a piece fo code that I need to modify to return the number of bytes in a smart array of type <char>. Anyone know how to do this? I don't use smart types (I think they are yucky), but I have to fix someone elses code on this one.
Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.
thx![]()
Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.
Note that the only definite guarantee that C and C++ give about sizes of types is that sizeof(char) == 1. That's because other types are measured in terms of char.
All the buzzt!
CornedBee
"There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
- Flon's Law
I see you using a lot of windows-esque notation in some of your other code. Are you working with chars or TCHARs?