aboutsummaryrefslogtreecommitdiffstats
path: root/docs/yul.rst
diff options
context:
space:
mode:
Diffstat (limited to 'docs/yul.rst')
-rw-r--r--docs/yul.rst9
1 files changed, 5 insertions, 4 deletions
diff --git a/docs/yul.rst b/docs/yul.rst
index 9e50f126..627e6e7c 100644
--- a/docs/yul.rst
+++ b/docs/yul.rst
@@ -130,9 +130,10 @@ Restrictions on the Grammar
---------------------------
Switches must have at least one case (including the default case).
-If all possible values of the expression is covered, the default case should
-not be allowed (i.e. a switch with a ``bool`` expression and having both a
-true and false case should not allow a default case).
+If all possible values of the expression are covered, a default case should
+not be allowed (i.e. a switch with a ``bool`` expression that has both a
+true and a false case should not allow a default case). All case values need to
+have the same type.
Every expression evaluates to zero or more values. Identifiers and Literals
evaluate to exactly
@@ -171,7 +172,7 @@ As an exception, identifiers defined in the "init" part of the for-loop
(the first block) are visible in all other parts of the for-loop
(but not outside of the loop).
Identifiers declared in the other parts of the for loop respect the regular
-syntatical scoping rules.
+syntactical scoping rules.
The parameters and return parameters of functions are visible in the
function body and their names cannot overlap.