about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2013-12-15 15:16:28 -0800
committerbors <bors@rust-lang.org>2013-12-15 15:16:28 -0800
commit9eb89a6c6e60b0ed844258b6c00a68973828b0ba (patch)
tree6d7a379d866e6c0ab60a5449f75c172b7e871cae
parentebbd30b5b2699c3f16a3387ed0851a2831076295 (diff)
parentb1b905f30b3d9b124f87780e63f279dad071d721 (diff)
downloadrust-9eb89a6c6e60b0ed844258b6c00a68973828b0ba.tar.gz
rust-9eb89a6c6e60b0ed844258b6c00a68973828b0ba.zip
auto merge of #10982 : ezyang/rust/lvalue-def, r=pcwalton
Based off of Niko's proposed definition of lvalues.

Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
-rw-r--r--doc/rust.md6
1 files changed, 5 insertions, 1 deletions
diff --git a/doc/rust.md b/doc/rust.md
index 92d5ee21222..aa4ce002e02 100644
--- a/doc/rust.md
+++ b/doc/rust.md
@@ -2177,7 +2177,11 @@ Expressions are divided into two main categories: _lvalues_ and _rvalues_.
 Likewise within each expression, sub-expressions may occur in _lvalue context_ or _rvalue context_.
 The evaluation of an expression depends both on its own category and the context it occurs within.
 
-[Path](#path-expressions), [field](#field-expressions) and [index](#index-expressions) expressions are lvalues.
+An lvalue is an expression that represents a memory location. These
+expressions are [paths](#path-expressions) (which refer to local
+variables, function and method arguments, or static variables),
+dereferences (`*expr`), [indexing expressions](#index-expressions)
+(`expr[expr]`), and [field references](#field-expressions) (`expr.f`).
 All other expressions are rvalues.
 
 The left operand of an [assignment](#assignment-expressions),