RosettaCodeData/Task/Exceptions/Langur/exceptions-1.langur

13 lines
190 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
throw "not a math exception"
2024-04-19 16:56:29 -07:00
catch[.e] {
if .e'cat == "math" {
2023-07-01 11:58:00 -04:00
# change result...
} else {
# rethrow the exception
throw
}
} else {
# no exception
}