From f66f3a87a62598913b7775285ecb31064a5c6e78 Mon Sep 17 00:00:00 2001 From: Simon Brand Date: Sun, 22 Oct 2017 09:53:19 +0100 Subject: [PATCH] Typo --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2a3f46e..ba6d518 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ The interface is the same as `std::optional`, but the following member functions * `tl::optional stoi (const std::string& s);` * `tl::optional i = opt_string.and_then(stoi);` - `or_else`: calls some function if there is no value stored. - * `opt.or_else([] { throw std::runtime_error{"oh no"]; });` + * `opt.or_else([] { throw std::runtime_error{"oh no"}; });` - `map_or`: carries out a `map` if there is a value, otherwise returns a default value. * `tl::optional s = opt_string.map_or(&std::string::size, 0);` - `map_or_else`: carries out a `map` if there is a value, otherwise returns the result of a given default function.