You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 96cd831
Browse filesBrowse the repository at this point in the historyBrowse files
##### `raise` vs `E2MM#Raise` for raising (and defining) exceptions [code](code/general/raise-vs-e2mmap.rb)[custom exception code](code/general/raise-custom-vs-e2mmap.rb)
198
198
199
-
Ruby's [Exception2MessageMapper module](http://ruby-doc.org/stdlib-2.2.0/libdoc/e2mmap/rdoc/index.html) allows one to define and raise exceptions with predefined messages.
199
+
Ruby's [Exception2MessageMapper module](https://ruby-doc.org/stdlib-2.2.0/libdoc/e2mmap/rdoc/index.html) allows one to define and raise exceptions with predefined messages.
200
200
201
201
```
202
202
$ ruby -v code/general/raise-vs-e2mmap.rb
@@ -1250,7 +1250,7 @@ Comparison:
1250
1250
##### `Hash#[]` vs `Hash#fetch`[code](code/hash/bracket-vs-fetch.rb)
1251
1251
1252
1252
If you use Ruby 2.2, `Symbol` could be more performant than `String` as `Hash` keys.
1253
-
Read more regarding this: [Symbol GC in Ruby 2.2](http://www.sitepoint.com/symbol-gc-ruby-2-2/) and [Unraveling String Key Performance in Ruby 2.2](http://www.sitepoint.com/unraveling-string-key-performance-ruby-2-2/).
1253
+
Read more regarding this: [Symbol GC in Ruby 2.2](https://www.sitepoint.com/symbol-gc-ruby-2-2/) and [Unraveling String Key Performance in Ruby 2.2](https://web.archive.org/web/20151222034748/http://www.sitepoint.com:80/unraveling-string-key-performance-ruby-2-2/).
1254
1254
1255
1255
```
1256
1256
$ ruby -v code/hash/bracket-vs-fetch.rb
@@ -1275,7 +1275,7 @@ Comparison:
1275
1275
1276
1276
##### `Hash#dig` vs `Hash#[]` vs `Hash#fetch`[code](code/hash/dig-vs-[]-vs-fetch.rb)
1277
1277
1278
-
[Ruby 2.3 introduced `Hash#dig`](http://ruby-doc.org/core-2.3.0/Hash.html#method-i-dig) which is a readable
1278
+
[Ruby 2.3 introduced `Hash#dig`](https://ruby-doc.org/core-2.3.0/Hash.html#method-i-dig) which is a readable
1279
1279
and performant option for retrieval from a nested hash, returning `nil` if an extraction step fails.
1280
1280
See [#102 (comment)](https://github.com/fastruby/fast-ruby/pull/102#issuecomment-198827506) for more info.
1281
1281
@@ -1308,7 +1308,7 @@ Comparison:
1308
1308
1309
1309
##### `Hash[]` vs `Hash#dup`[code](code/hash/bracket-vs-dup.rb)
0 commit comments