about summary refs log tree commit diff
path: root/src/libsyntax/parse
diff options
context:
space:
mode:
Diffstat (limited to 'src/libsyntax/parse')
-rw-r--r--src/libsyntax/parse/mod.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/libsyntax/parse/mod.rs b/src/libsyntax/parse/mod.rs
index 9bcf1079a64..ea5d6739e6d 100644
--- a/src/libsyntax/parse/mod.rs
+++ b/src/libsyntax/parse/mod.rs
@@ -120,6 +120,10 @@ pub fn parse_expr_from_source_str<'a>(name: String,
     p.parse_expr()
 }
 
+/// Parses an item.
+///
+/// Returns `Ok(Some(item))` when successful, `Ok(None)` when no item was found, and`Err`
+/// when a syntax error occurred.
 pub fn parse_item_from_source_str<'a>(name: String,
                                       source: String,
                                       cfg: ast::CrateConfig,