Added std/oserrors for OS error reporting (#19390)
* Added 'std/oserrors' for OS error reporting * add a simple test * New code should not support -d:useWinAnsi anymore thanks to @Araq
This commit is contained in:
parent
07c7a8a526
commit
bc3bee5469
3 changed files with 129 additions and 0 deletions
9
tests/stdlib/toserrors.nim
Normal file
9
tests/stdlib/toserrors.nim
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
discard """
|
||||
action: compile
|
||||
"""
|
||||
|
||||
import std/oserrors
|
||||
|
||||
let x1 = osLastError()
|
||||
raiseOSError(x1)
|
||||
echo osErrorMsg(x1)
|
||||
Loading…
Add table
Add a link
Reference in a new issue