Kernel 0.93+

This commit is contained in:
Rémy GIBERT 2020-01-07 14:44:38 +01:00
parent 2670cdf560
commit 35f4254598
6 changed files with 34 additions and 39 deletions

Binary file not shown.

View File

@ -105,7 +105,6 @@ CMD.CD.YA >SYSCALL realpath
jsr IO.StatYA
bcs .19
.10 >LDA.G StatBuf+S.STAT.P.TYPE
cmp #S.FI.T.DIR
beq .11
lda #MLI.E.INVPATH
@ -307,9 +306,9 @@ CMD.DATE >LEA.G TimeBuf
.2 >PUSHYA
>LEA.G StatBuf
>LDYA ZPCLBuf
>SYSCALL StrFTime
>LEA.G StatBuf
>LDYA ZPCLBuf
>SYSCALL puts
rts
*--------------------------------------
@ -454,13 +453,12 @@ CMD.PWD jsr GetCWD
CMD.RD lda (ZPArgVBufPtr)
beq CMD.REN.CSYN
>LDYA ZPArgVBufPtr
jsr IO.StatYA
jsr IO.StatArgVBufPtr
bcs .99
>LDA.G StatBuf+S.STAT.P.TYPE
cmp #S.FI.T.DIR
bne CMD.REN.CSYN
>LDYA ZPArgVBufPtr
>SYSCALL Remove
.99 rts

View File

@ -483,11 +483,14 @@ CORE.ArgV.NextChar
*--------------------------------------
CORE.ArgV.Next lda (ZPArgVBufPtr)
beq .8
>LDYA ZPArgVBufPtr
>STYA ZPArgVBufPrev
.1 jsr CORE.ArgV.NextChar
lda (ZPArgVBufPtr)
bne .1
jsr CORE.ArgV.NextChar
lda (ZPArgVBufPtr)

View File

@ -136,49 +136,39 @@ EXP.TEST.UNARY jsr CORE.ArgV.Next
EXP.OP.UNARY.ESYN
jmp EXP.E.ESYN
EXP.OP.UNARY.D jsr EXP.OP.UNARY.STAT
EXP.OP.UNARY.D jsr IO.StatArgVBufPtr
bcs EXP.OP.UNARY.DEF.9
>LDA.G StatBuf+S.STAT.P.TYPE
cmp #S.FI.T.DIR
bne EXP.OP.UNARY.DEF.9
bra EXP.OP.UNARY.DEF.8
EXP.OP.UNARY.E jsr EXP.OP.UNARY.STAT
EXP.OP.UNARY.E jsr IO.StatArgVBufPtr
bcs EXP.OP.UNARY.DEF.9
bra EXP.OP.UNARY.DEF.8 DIR or FILE exist
EXP.OP.UNARY.F jsr EXP.OP.UNARY.STAT
EXP.OP.UNARY.F jsr IO.StatArgVBufPtr
bcs EXP.OP.UNARY.DEF.9
>LDA.G StatBuf+S.STAT.P.TYPE
cmp #S.FI.T.DIR
beq EXP.OP.UNARY.DEF.9
bra EXP.OP.UNARY.DEF.8
EXP.OP.UNARY.STAT
>LDYA ZPArgVBufPtr
jsr IO.StatYA
php
jsr CORE.ArgV.Next
plp
rts
EXP.OP.UNARY.DEF.8
lda #$80 true
clc
rts
sec true
.HS 90 BCC
EXP.OP.UNARY.DEF.9
lda #0 false
clc false
jsr CORE.ArgV.Next
lda #0
lsr
clc
EXP.OP.UNARY.DEF.RTS
rts
*--------------------------------------
EXP.OP.UNARY.I jsr EXP.GetInt32Arg
php
jsr CORE.ArgV.Next
plp
bcs EXP.OP.UNARY.DEF.9
inc pStack Discard Long
@ -200,12 +190,11 @@ EXP.OP.UNARY.Z lda (ZPArgVBufPtr) [ -Z ] ?
beq EXP.OP.UNARY.DEF.8 TRUE
jsr CORE.ArgV.Next
beq EXP.TEST.BINARY.ESYN
cmp #']'
bne EXP.TEST.BINARY.ESYN
bra EXP.OP.UNARY.DEF.9 FALSE
*--------------------------------------
EXP.OP.UNARY.X jsr CMD.CALL.GETFUNC
php
jsr CORE.ArgV.Next
plp
bcs EXP.OP.UNARY.DEF.9 FALSE
bra EXP.OP.UNARY.DEF.8 TRUE
*--------------------------------------

View File

@ -147,13 +147,18 @@ IO.FOpenYAX pha
>SYSCALL fopen
rts
*--------------------------------------
IO.StatYA phy
pha
>PUSHEA.G StatBuf
IO.StatArgVBufPtr
>LDYA ZPArgVBufPtr
IO.StatYA pha
>PUSHW ZPCLBuf
pla
ply
>SYSCALL STAT
rts
bcs .9
ldy #S.STAT.P.TYPE
lda (ZPCLBuf),y
.9 rts
*--------------------------------------
IO.PrintBatchErrMsg
>LDYA ZPInputBuf

View File

@ -697,8 +697,6 @@ bREAD.S .BS 1
READ.N .BS 1
Sleep .BS 4
StatBuf .BS S.STAT
TimeBuf .BS S.TIME
CL.hCLBuf .BS 1
CL.Ptr .BS 1
@ -718,7 +716,9 @@ IO.hIn .BS 1
IO.hOut .BS 1
IO.hErr .BS 1
*TimeBuf .BS S.TIME 8 bytes
*M32.BUF .BS 12 -1234567890\0
TimeBuf .EQ *
M32.BUF .EQ *
IO.FIFO .BS 12 /DEV/FIFOxx\0
*--------------------------------------