Skip to content

Commit 436edd8

Browse files
authored
add sys.exit (#132)
1 parent fd8283d commit 436edd8

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/stdlib/Sys.fs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,15 @@ type IExports =
2828
abstract prefix: string
2929
abstract version: string
3030
abstract version_info: VersionInfo
31+
/// Exits with code 0, indicating success
32+
/// See https://docs.python.org/3/library/sys.html#sys.exit
33+
abstract exit: unit -> 'a
34+
/// Exits with provided status
35+
/// See https://docs.python.org/3/library/sys.html#sys.exit
36+
abstract exit: status: int -> 'a
37+
/// Exits with exit status 1, printing message to stderr
38+
/// See https://docs.python.org/3/library/sys.html#sys.exit
39+
abstract exit: message: string -> 'a
3140

3241
/// System-specific parameters and functions
3342
[<ImportAll("sys")>]

0 commit comments

Comments
 (0)