Welcome to the Parallax Discussion Forums, sign-up to participate.
I feel like a total noob here. The shifts I have no problem with. I can write this in standalone assembly. But I have utterly no idea how to "hook-up" the assembly stuff to the input params, and then "get the answer" out of the assembly block and into the BASIC RETURN value. Can anyone enlighten me how this works?
dim myVar, shifts as uLong myVar = 1024 shifts = 8 print BitShiftRight(myVar, shifts) FUNCTION BitShiftRight(x as ulong, y as ulong) as ulong 'shifts X to right Y places dim theAnswer as ulong ASM (dark magic happens here to get stuff into, and out of the assembly block after shifting X to the right Y places) END ASM return theAnswer END FUNCTION