Hi,
ANS states clearly, that programs do have to take care about
alignement. But if I do have data that comes from say a file from
another machine, I want to read this. So I've to do things like
\ VAX-order
: v@[EMAIL PROTECTED]
dup c@[EMAIL PROTECTED]
over 1+ c@[EMAIL PROTECTED]
8 << or
over 2 + c@[EMAIL PROTECTED]
16 << or
swap 3 + c@[EMAIL PROTECTED]
24 << or ;
\ Network-order
: n@[EMAIL PROTECTED]
dup c@[EMAIL PROTECTED]
24 <<
over 1+ c@[EMAIL PROTECTED]
16 << or
over 2 + c@[EMAIL PROTECTED]
8 << or
swap 3 + c@[EMAIL PROTECTED]
or ;
Is there any common practise how to name such words? Perl for example
has it's pack/unpack to do such things and I could imagine I'm not the
first that stumbles about this problem.
Regards,
-Helmar