aboutsummaryrefslogtreecommitdiffstats
path: root/lib/parsetools
diff options
context:
space:
mode:
authorHenrik Nord <[email protected]>2014-02-24 16:15:11 +0100
committerHenrik Nord <[email protected]>2014-02-24 16:15:11 +0100
commit9fd8dfa8c3fed9981191f16cd5c3d5cded3660ae (patch)
tree27ce5dfd72b712a6a02d80fddd5519456874754d /lib/parsetools
parent109a06739bdbb5ca1e21cea2d4cf288fc0848d57 (diff)
parentb258165f5f000e77ca3e73cf7be38ae53c33a459 (diff)
downloadotp-9fd8dfa8c3fed9981191f16cd5c3d5cded3660ae.tar.gz
otp-9fd8dfa8c3fed9981191f16cd5c3d5cded3660ae.tar.bz2
otp-9fd8dfa8c3fed9981191f16cd5c3d5cded3660ae.zip
Merge branch 'fenollp/yecc-bad-example-code/OTP-11749'
* fenollp/yecc-bad-example-code/OTP-11749: Replace fixed-length list-nodes by tuple-nodes
Diffstat (limited to 'lib/parsetools')
-rw-r--r--lib/parsetools/doc/src/yecc.xml8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/parsetools/doc/src/yecc.xml b/lib/parsetools/doc/src/yecc.xml
index 380cac967a..7298e09c2c 100644
--- a/lib/parsetools/doc/src/yecc.xml
+++ b/lib/parsetools/doc/src/yecc.xml
@@ -425,9 +425,9 @@ myparser:parse_and_scan({Mod, Tokenizer, Args}) </code>
Nonterminals E T F.
Terminals '+' '*' '(' ')' number.
Rootsymbol E.
-E -> E '+' T: ['$2', '$1', '$3'].
+E -> E '+' T: {'$2', '$1', '$3'}.
E -> T : '$1'.
-T -> T '*' F: ['$2', '$1', '$3'].
+T -> T '*' F: {'$2', '$1', '$3'}.
T -> F : '$1'.
F -> '(' E ')' : '$2'.
F -> number : '$1'. </code>
@@ -438,8 +438,8 @@ Terminals '+' '*' '(' ')' number.
Rootsymbol E.
Left 100 '+'.
Left 200 '*'.
-E -> E '+' E : ['$2', '$1', '$3'].
-E -> E '*' E : ['$2', '$1', '$3'].
+E -> E '+' E : {'$2', '$1', '$3'}.
+E -> E '*' E : {'$2', '$1', '$3'}.
E -> '(' E ')' : '$2'.
E -> number : '$1'. </code>
<p>3. An overloaded minus operator:</p>