[comp.sys.amiga] Alignment issue resolved

john13@garfield.UUCP (John Russell) (01/13/88)

Thanks to those who replied on the question of how to create an array of 1
type (eg UBYTE) which would be guaranteed to be aligned on a certain boundary
(eg longword boundary).

The answer is to use a union, then you can refer to the members of the array
(or whatever) as items of either type. 

This has now been installed and works fine in the program I needed it for,
resulting in a noticeable speed increase -- 2 long compares vs 8 byte
compares. The only thing is, now the cordless phone in the other room beeps
in another rhythm when it hits that subroutine :-) (it really does!).

John

PS Now all I'm missing is some comprehensive Clipboard routines. But I may
post v1.0 of the program without them since it works fine using the "write to
pipe: file" option.
-- 
"Operating systems room, prepare for shutdown."
"I never thought I'd be HAPPY to see our ratings do DOWN!"
		-- lots of these were sprinkled throughout the 
		   last broadcast episode of _Max_Headroom_