Author Topic: is this complicated ?  (Read 4834 times)

0 Members and 2 Guests are viewing this topic.

Peter

  • Guest
Re: is this complicated ?
« Reply #15 on: August 21, 2012, 05:50:52 AM »
Code: [Select]
Macro LoWord(a)
a & 0xFFFF    'Low part
End Macro

Macro HiWord(a)
a>>16           'High part
End Macro

a=0xFFFF0064

print HiWord(a)  '65535
print LoWord(a)  '100
'&' is a bit better because
'AND' is logic, not a bit operation in BASIC!

Charles Pegge

  • Guest
Re: is this complicated ?
« Reply #16 on: August 21, 2012, 07:42:28 AM »
Hi Peter,

OxygenBasic conflates bitwise and logical operators. Both forms translate to something like:

mov eax,a
and eax,0xffff


Charles

Aurel

  • Guest
Re: is this complicated ?
« Reply #17 on: October 19, 2012, 12:58:34 PM »
Well i do not know nothing about def
and i just see first time that def contain whole block of code ???
I really think that is time Charles that you explain or create help file
with closer explanation what is and how to use :
macro and def and some other things...
do you agree...?