Closed
Description
I recently came across something like this:
def test():
quit(10)
test()
$ lpython a.py
err = 2560
STOP
$ echo $?
1
So, I thought to replace this with the following change:
if (err != 0) {
if (0 < err && err < 256) {
return err;
} else if (err % 256 == 0) {
return err / 256;
} else {
return 1;
}
}
Originally posted by @Thirumalai-Shaktivel in #1302 (comment)
Metadata
Metadata
Assignees
Labels
No labels