Change rules for promotion of floats
Posted: Sun Oct 05, 2008 3:29 pm
Hi,
Could the rules for promotion of floats be changed so that any integer only operations which are contained in parenthesis are carried out before the promotion? Or that the promotion only occurs when required?
For example, with macros ported from the Windows API you need an extra step to assign to a float:
Could the rules for promotion of floats be changed so that any integer only operations which are contained in parenthesis are carried out before the promotion? Or that the promotion only occurs when required?
For example, with macros ported from the Windows API you need an extra step to assign to a float:
Code: Select all
EnableExplicit
Define wparam.l
Define distance.f
Define temp.l
Macro HIWORD(l) : (((l) >> 16) & $FFFF) : EndMacro
; distance = HIWORD(wparam)
temp = HIWORD(wparam)
distance = temp