summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2010-09-13 17:48:02 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2010-09-13 17:48:02 +0000
commit2716b9ae54da4b558c90a99b2f3fc54b118cd717 (patch)
treecf9ae233b2fd6723398ade98f90c24a2a1116865
parent9fd2ed924358c2fb4950c8189c8fc14c922fd629 (diff)
downloadbcm5719-llvm-2716b9ae54da4b558c90a99b2f3fc54b118cd717.tar.gz
bcm5719-llvm-2716b9ae54da4b558c90a99b2f3fc54b118cd717.zip
Update 'docs/PCHInternals.html' about how subexpressions are stored.
llvm-svn: 113760
-rw-r--r--clang/docs/PCHInternals.html8
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/docs/PCHInternals.html b/clang/docs/PCHInternals.html
index 109d5ed0255..d46ae5ceec1 100644
--- a/clang/docs/PCHInternals.html
+++ b/clang/docs/PCHInternals.html
@@ -391,23 +391,23 @@ precompiled header, which contains the serialized representation of
that statement or expression. Each substatement or subexpression
within an expression is stored as a separate record (which keeps most
records to a fixed size). Within the precompiled header, the
-subexpressions of an expression are stored prior to the expression
+subexpressions of an expression are stored, in reverse order, prior to the expression
that owns those expression, using a form of <a
href="http://en.wikipedia.org/wiki/Reverse_Polish_notation">Reverse
Polish Notation</a>. For example, an expression <code>3 - 4 + 5</code>
would be represented as follows:</p>
<table border="1">
- <tr><td><code>IntegerLiteral(3)</code></td></tr>
+ <tr><td><code>IntegerLiteral(5)</code></td></tr>
<tr><td><code>IntegerLiteral(4)</code></td></tr>
+ <tr><td><code>IntegerLiteral(3)</code></td></tr>
<tr><td><code>BinaryOperator(-)</code></td></tr>
- <tr><td><code>IntegerLiteral(5)</code></td></tr>
<tr><td><code>BinaryOperator(+)</code></td></tr>
<tr><td>STOP</td></tr>
</table>
<p>When reading this representation, Clang evaluates each expression
-record it encounters, builds the appropriate abstract synax tree node,
+record it encounters, builds the appropriate abstract syntax tree node,
and then pushes that expression on to a stack. When a record contains <i>N</i>
subexpressions--<code>BinaryOperator</code> has two of them--those
expressions are popped from the top of the stack. The special STOP
OpenPOWER on IntegriCloud