From ae70529f2041dd6c0c6f9831450acafd91cad3c8 Mon Sep 17 00:00:00 2001 From: altrisi Date: Sun, 21 Feb 2021 02:50:49 +0100 Subject: [PATCH] Mention error in docs --- docs/scarpet/language/FunctionsAndControlFlow.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/scarpet/language/FunctionsAndControlFlow.md b/docs/scarpet/language/FunctionsAndControlFlow.md index 4562b4dd..79c931a3 100644 --- a/docs/scarpet/language/FunctionsAndControlFlow.md +++ b/docs/scarpet/language/FunctionsAndControlFlow.md @@ -286,6 +286,8 @@ You can specify the `parent` to be either an already existing exception from the will not inherit from `user_defined_exception`, or specify a custom one, in which case your exception will inherit from `exception` > `user_defined_exception` > `parent` > `id`. +If you don't want your exception to be handled, you can use `error` as the `parent` to throw an error which cannot be handled. + Deprecated usage: `throw()` (without id): Specify at least the id of your exception ### `if(cond, expr, cond?, expr?, ..., default?)`