mirror of
https://github.com/uffejakobsen/acme.git
synced 2024-12-23 10:29:46 +00:00
fixed float macros in library to make sure they work with future versions of ACME
git-svn-id: https://svn.code.sf.net/p/acme-crossass/code-0/trunk@134 4df02467-bbd4-4a76-a152-e7ce94205b78
This commit is contained in:
parent
d1ac849272
commit
ef3cbbe340
@ -47,9 +47,10 @@ lib_cbm_flpt_a = 1
|
||||
; this is ugly, but it gets the job done
|
||||
; (if it's stupid, but it works, then it's not stupid)
|
||||
!macro flpt @value {
|
||||
!set @float = float(@value) ; make sure to do passes until value is defined
|
||||
!set @float = float(@value)
|
||||
!ifndef @float {
|
||||
!by $ff, $ff, $ff, $ff, $ff, $ff ; six place holder bytes
|
||||
!by <@float, $ff, $ff, $ff, $ff, $ff ; six place holder bytes
|
||||
; (first one depends on @float just to make sure more passes are done until value is defined)
|
||||
} else {
|
||||
; value is defined, so split up into sign and non-negative value
|
||||
!if @float < 0 {
|
||||
|
@ -42,9 +42,10 @@ lib_cbm_mflpt_a = 1
|
||||
; this is ugly, but it gets the job done
|
||||
; (if it's stupid, but it works, then it's not stupid)
|
||||
!macro mflpt @value {
|
||||
!set @float = float(@value) ; make sure to do passes until value is defined
|
||||
!set @float = float(@value)
|
||||
!ifndef @float {
|
||||
!by $ff, $ff, $ff, $ff, $ff ; five place holder bytes
|
||||
!by <@float, $ff, $ff, $ff, $ff ; five place holder bytes
|
||||
; (first one depends on @float just to make sure more passes are done until value is defined)
|
||||
} else {
|
||||
; value is defined, so split up into sign and non-negative value
|
||||
!if @float < 0 {
|
||||
|
Loading…
Reference in New Issue
Block a user