Skip to content

Commit

Permalink
Include "flatmap" in docs of Option::and_then
Browse files Browse the repository at this point in the history
Some newcomers might look for a "flatMap" method on Option. Include the
reference so that searching the page would find "and_then".
  • Loading branch information
robinst committed Feb 15, 2015
1 parent b6d91a2 commit dab626b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/libcore/option.rs
Expand Up @@ -605,6 +605,8 @@ impl<T> Option<T> {
/// Returns `None` if the option is `None`, otherwise calls `f` with the
/// wrapped value and returns the result.
///
/// Some languages call this operation flatmap.
///
/// # Example
///
/// ```
Expand Down

0 comments on commit dab626b

Please sign in to comment.