mirror of
https://github.com/byteworksinc/ORCA-C.git
synced 2025-02-08 18:30:35 +00:00
Properly report dates in the year 2000 and beyond with the __DATE__ macro.
This should now work properly through the end of the year 2155, i.e. the limit of what the ReadTimeHex format can represent.
This commit is contained in:
parent
af48935d43
commit
1994e7e353
14
Scanner.asm
14
Scanner.asm
@ -602,8 +602,20 @@ SetDateTime private
|
|||||||
sta time+2
|
sta time+2
|
||||||
pla set the year
|
pla set the year
|
||||||
xba
|
xba
|
||||||
|
and #$00FF
|
||||||
|
ldy #19
|
||||||
|
yearloop sec
|
||||||
|
sbc #100
|
||||||
|
bmi yeardone
|
||||||
|
iny
|
||||||
|
bra yearloop
|
||||||
|
yeardone clc
|
||||||
|
adc #100
|
||||||
jsr convert
|
jsr convert
|
||||||
sta date+11
|
sta date+11
|
||||||
|
tya
|
||||||
|
jsr convert
|
||||||
|
sta date+9
|
||||||
lda 1,S set the day
|
lda 1,S set the day
|
||||||
inc A
|
inc A
|
||||||
jsr convert
|
jsr convert
|
||||||
@ -624,7 +636,7 @@ SetDateTime private
|
|||||||
rtl
|
rtl
|
||||||
|
|
||||||
month dc c'Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec'
|
month dc c'Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec'
|
||||||
date dc i'12',c'mmm dd 19yy',i1'0'
|
date dc i'12',c'mmm dd YYyy',i1'0'
|
||||||
time dc i'9',c'hh:mm:ss',i1'0'
|
time dc i'9',c'hh:mm:ss',i1'0'
|
||||||
|
|
||||||
convert and #$00FF
|
convert and #$00FF
|
||||||
|
Loading…
x
Reference in New Issue
Block a user