[holy ruby programmers batman!] Fwd: hash math subtraction becomes non-destructive

Giles Bowkett gilesb at gmail.com
Mon Mar 3 14:06:41 EST 2008

If anyone has a second to play with this, I think it should *probably*
be added in.

---------- Forwarded message ----------
From: Jimmy Whiteman <jimtron9000 at gmail.com>
Date: Feb 7, 2008 7:51 PM
Subject: Utility Belt
To: Giles Bowkett <gilesb at gmail.com>


I just downloaded and started playing with your Utility Belt gem.
Having lots of fun... thanks.
I normally just required Active Support, but this is much more in line
with what I like to do.

Anyhoo, I've included a patch for making Hash#- (hash subtraction)
Presently,  @a + at b will not alter @a (your using merge instead of
merge!) but @a - @b will alter
@a (delete acts like a delete! method). I added few behaviors to the
spec to show my intentions.

Thanks again -- and take care,

PS => let me know if I've botched the diff. I'm a patch-sending-newbie!

Giles Bowkett

Blog: http://gilesbowkett.blogspot.com
Portfolio: http://www.gilesgoatboy.org
Tumblelog: http://giles.tumblr.com
Podcast: http://hollywoodgrit.blogspot.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: made_hash_math_subtraction_non_destructive.diff
Type: application/octet-stream
Size: 1598 bytes
Desc: not available
Url : http://rubyforge.org/pipermail/utilitybelt-tinkering/attachments/20080303/9c20595f/attachment.obj 

More information about the Utilitybelt-tinkering mailing list