aboutsummaryrefslogtreecommitdiff
path: root/lib/core
diff options
context:
space:
mode:
Diffstat (limited to 'lib/core')
-rw-r--r--lib/core/control_flow.nom7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/core/control_flow.nom b/lib/core/control_flow.nom
index bf044d9..415611b 100644
--- a/lib/core/control_flow.nom
+++ b/lib/core/control_flow.nom
@@ -39,6 +39,13 @@ test:
end
")
+(else $) compiles to:
+ at (this tree) fail ("
+ Compile error: This 'else' is not connected to any 'if' or 'unless' condition.
+ Hint: You should probably have a ".." in front of the "else", to indicate \
+ ..that it's attached to the previous condition.
+ ")
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Conditional expression (ternary operator)