Skip to content

Commit 8da650f

Browse files
authored
Merge pull request #527 from boriel/feature/rename_esxdos_macros
Feature/rename esxdos macros
2 parents f6fce60 + dca7b76 commit 8da650f

2 files changed

Lines changed: 96 additions & 0 deletions

File tree

src/arch/zx48k/library/esxdos.bas

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,7 @@ Function ESXDosGetCwd as String
262262
Dim addr as Uinteger
263263

264264
Asm
265+
push namespace core
265266
proc
266267
local NotNull
267268

@@ -287,6 +288,7 @@ NotNull:
287288
db F_GETCWD
288289
pop ix
289290
endp
291+
pop namespace
290292
End Asm
291293

292294
cwd$ = ""
@@ -324,6 +326,7 @@ Function ESXDosOpenDir (ByVal path as String) as UInteger
324326
end if
325327

326328
Asm
329+
push namespace core
327330
Proc
328331
local NotNull
329332
local HandleOK
@@ -382,6 +385,7 @@ HandleOK:
382385

383386
ExitFunction:
384387
endp
388+
pop namespace
385389
End Asm
386390

387391
return handle
@@ -560,6 +564,7 @@ Sub ESXDosChDir (ByVal path as String)
560564
end if
561565

562566
Asm
567+
push namespace core
563568
Proc
564569
local NotNull
565570
local HandleOK
@@ -603,6 +608,7 @@ HandleOK:
603608
pop hl
604609
call __MEM_FREE ;deallocate mem
605610
endp
611+
pop namespace
606612
End Asm
607613

608614
End Sub
@@ -746,4 +752,46 @@ read_ok:
746752
End Asm
747753
End Sub
748754

755+
756+
' Remove macros
757+
#undef HOOK_BASE
758+
#undef MISC_BASE
759+
#undef FSYS_BASE
760+
#undef M_GETSETDRV
761+
#undef F_OPEN
762+
#undef F_CLOSE
763+
#undef F_READ
764+
#undef F_WRITE
765+
#undef F_SEEK
766+
#undef F_GETPOS
767+
#undef F_OPENDIR
768+
#undef F_READDIR
769+
#undef F_TELLDIR
770+
#undef F_SEEKDIR
771+
#undef F_REWINDDIR
772+
#undef F_GETCWD
773+
#undef F_CHDIR
774+
#undef F_MKDIR
775+
#undef F_RMDIR
776+
777+
#undef EDOS_FMODE_READ
778+
#undef EDOS_FMODE_WRITE
779+
#undef EDOS_FMODE_OPEN_EX
780+
#undef EDOS_FMODE_OPEN_AL
781+
#undef EDOS_FMODE_CREATE_NEW
782+
#undef EDOS_FMODE_CREATE_AL
783+
784+
#undef SEEK_START
785+
#undef SEEK_CUR
786+
#undef SEEK_BKCUR
787+
788+
#undef FATTR_RDONLY
789+
#undef FATTR_HIDDEN
790+
#undef FATTR_SYSTEM
791+
#undef FATTR_VOLUME
792+
#undef FATTR_DIR
793+
#undef FATTR_ARCHIVE
794+
795+
#undef EDOS_ERR_NR
796+
749797
#endif

src/arch/zxnext/library/esxdos.bas

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,7 @@ Function ESXDosGetCwd as String
262262
Dim addr as Uinteger
263263

264264
Asm
265+
push namespace core
265266
proc
266267
local NotNull
267268

@@ -287,6 +288,7 @@ NotNull:
287288
db F_GETCWD
288289
pop ix
289290
endp
291+
pop namespace
290292
End Asm
291293

292294
cwd$ = ""
@@ -324,6 +326,7 @@ Function ESXDosOpenDir (ByVal path as String) as UInteger
324326
end if
325327

326328
Asm
329+
push namespace core
327330
Proc
328331
local NotNull
329332
local HandleOK
@@ -382,6 +385,7 @@ HandleOK:
382385

383386
ExitFunction:
384387
endp
388+
pop namespace
385389
End Asm
386390

387391
return handle
@@ -560,6 +564,7 @@ Sub ESXDosChDir (ByVal path as String)
560564
end if
561565

562566
Asm
567+
push namespace core
563568
Proc
564569
local NotNull
565570
local HandleOK
@@ -603,6 +608,7 @@ HandleOK:
603608
pop hl
604609
call __MEM_FREE ;deallocate mem
605610
endp
611+
pop namespace
606612
End Asm
607613

608614
End Sub
@@ -746,4 +752,46 @@ read_ok:
746752
End Asm
747753
End Sub
748754

755+
756+
' Remove macros
757+
#undef HOOK_BASE
758+
#undef MISC_BASE
759+
#undef FSYS_BASE
760+
#undef M_GETSETDRV
761+
#undef F_OPEN
762+
#undef F_CLOSE
763+
#undef F_READ
764+
#undef F_WRITE
765+
#undef F_SEEK
766+
#undef F_GETPOS
767+
#undef F_OPENDIR
768+
#undef F_READDIR
769+
#undef F_TELLDIR
770+
#undef F_SEEKDIR
771+
#undef F_REWINDDIR
772+
#undef F_GETCWD
773+
#undef F_CHDIR
774+
#undef F_MKDIR
775+
#undef F_RMDIR
776+
777+
#undef EDOS_FMODE_READ
778+
#undef EDOS_FMODE_WRITE
779+
#undef EDOS_FMODE_OPEN_EX
780+
#undef EDOS_FMODE_OPEN_AL
781+
#undef EDOS_FMODE_CREATE_NEW
782+
#undef EDOS_FMODE_CREATE_AL
783+
784+
#undef SEEK_START
785+
#undef SEEK_CUR
786+
#undef SEEK_BKCUR
787+
788+
#undef FATTR_RDONLY
789+
#undef FATTR_HIDDEN
790+
#undef FATTR_SYSTEM
791+
#undef FATTR_VOLUME
792+
#undef FATTR_DIR
793+
#undef FATTR_ARCHIVE
794+
795+
#undef EDOS_ERR_NR
796+
749797
#endif

0 commit comments

Comments
 (0)