This commit is contained in:
Niels 2015-12-22 13:27:40 +01:00
parent 4351698c83
commit 67c2d90a21
10 changed files with 245 additions and 33 deletions

View file

@ -26,8 +26,8 @@ int main()
{
object.at("the fast") = "il rapido";
}
catch (std::out_of_range)
catch (std::out_of_range& e)
{
std::cout << "out of range" << '\n';
std::cout << "out of range: " << e.what() << '\n';
}
}

View file

@ -1 +1 @@
<a target="_blank" href="http://melpon.org/wandbox/permlink/syN4hQrhPvlUy5AG"><b>online</b></a>
<a target="_blank" href="http://melpon.org/wandbox/permlink/3ir8W1OZ5KtbRz6r"><b>online</b></a>

View file

@ -1,3 +1,3 @@
"il brutto"
{"the bad":"il cattivo","the good":"il buono","the ugly":"il brutto"}
out of range
out of range: key 'the fast' not found

View file

@ -21,8 +21,8 @@ int main()
{
array.at(5) = "sixth";
}
catch (std::out_of_range)
catch (std::out_of_range& e)
{
std::cout << "out of range" << '\n';
std::cout << "out of range: " << e.what() << '\n';
}
}

View file

@ -1 +1 @@
<a target="_blank" href="http://melpon.org/wandbox/permlink/wKBBW3ORmTHPlgJV"><b>online</b></a>
<a target="_blank" href="http://melpon.org/wandbox/permlink/9Ae4DO4HJjULnq5j"><b>online</b></a>

View file

@ -1,3 +1,3 @@
"third"
["first","second","third","fourth"]
out of range
out of range: array index 5 is out of range