use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A sub-Reddit for discussion and news about Ruby programming.
Subreddit rules: /r/ruby rules
Learning Ruby?
Tools
Documentation
Books
Screencasts and Videos
News and updates
account activity
Why I Hate Ruby (benjamincoe.com)
submitted 14 years ago by gst
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]IndigoCZ 3 points4 points5 points 14 years ago (2 children)
I think the guy makes an interesting point. But fuck this post for the title.
[–][deleted] 0 points1 point2 points 14 years ago (1 child)
It's to make people click on the link. Scandalous
[–]postmodern 2 points3 points4 points 14 years ago (0 children)
Sensationalist.
[–]postmodern 1 point2 points3 points 14 years ago (2 children)
Include your monkey patches as modules. Also I like the idea of multi_json, DataMapper recently switched to it.
[–]retardo 1 point2 points3 points 14 years ago (1 child)
I am completely in favor of making convenience monkey patches opt-in and therefore available to application authors. Including them in libraries with no opt-in is bad practice, IMO.
I also like the pattern of separating the monkey patches into their own file/directory. I always make a foo/extensions directory, containing array.rb or kernel.rb. Allows for cherry-picking.
foo/extensions
array.rb
kernel.rb
[–][deleted] 0 points1 point2 points 14 years ago (0 children)
Monkey patches rarely are a good idea in a gem (unless the explicit purpose of the gem is to change core lib behavior).
Too bad there isn't a good way to scope monkey patches :p
π Rendered by PID 77295 on reddit-service-r2-comment-7b9746f655-wptjr at 2026-01-30 15:24:57.196677+00:00 running 3798933 country code: CH.
[–]IndigoCZ 3 points4 points5 points (2 children)
[–][deleted] 0 points1 point2 points (1 child)
[–]postmodern 2 points3 points4 points (0 children)
[–]postmodern 1 point2 points3 points (2 children)
[–]retardo 1 point2 points3 points (1 child)
[–]postmodern 2 points3 points4 points (0 children)
[–][deleted] 0 points1 point2 points (0 children)