This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

this is non portable code ?


unsigned char buf[100]
.
.
.
unsigned int val;
.
.
.
val = *((unsigned int *)(&buf[1]));
.
.
.

comments?

Parents
  • No two-step translation involved. However, I sometimes gets parity bit errors - especially when someone comes in and wants to talk to me in the middle of writing :)

    Sw: från = Eng: from. They start the same, the same number of letters and similar pronounciation.

    IBM had 36-bit big iron, so they impplemented 4x 9-bit characters or 5x 7-bit characters.

Reply
  • No two-step translation involved. However, I sometimes gets parity bit errors - especially when someone comes in and wants to talk to me in the middle of writing :)

    Sw: från = Eng: from. They start the same, the same number of letters and similar pronounciation.

    IBM had 36-bit big iron, so they impplemented 4x 9-bit characters or 5x 7-bit characters.

Children
  • Control Data Corporation's "Cyber" machines used 6-bit characters and a 60-bit word. The OS had a special "ASCII" mode that translated files with special multi-byte escape sequences to represent both upper and lower case. Writing character values in octal actually made sense for this machine.