hoodwink.d enhanced
RSS
2.0
XHTML
1.0

RedHanded

Wednesday

2005.02.23

Ruby Turns Twelve #

by why in cult

...while the rest of us continue to insist upon living out our youth through her.

I’d personally like to encourage Matz to take the day off, relax, maybe make a few appearances for the public’s benefit, accept their accolades and exhale with contentment. Today, we celebrate twelve years since an idea popped into that man’s head.

I wonder what I was doing that day. That was right around the time I made that handheld TV jammer and blocked out the closed-circuit high school news program in my English class. Nobody really cared. Definitely not worth talking about twelve years later.

Whoa, SCRIPT_LINES__?! #

by why in inspect

Did you know this? I had no idea. If you define SCRIPT_LINES__ constant as a Hash, then the source code for all load‘d or require‘d files will be stored in the Hash! The key is the path to the source file and the value is an array of strings, each a line of source code.

 >> SCRIPT_LINES__ = {}
 >> require 'drb'
 >> SCRIPT_LINES__.keys
 => ["/usr/local/lib/ruby/1.8/drb/drb.rb", 
     "/usr/local/lib/ruby/1.8/drb/eq.rb", 
     "/usr/local/lib/ruby/1.8/drb/invokemethod.rb", 
     "/usr/local/lib/ruby/1.8/thread.rb", 
     "/usr/local/lib/ruby/1.8/drb.rb"]
 >> SCRIPT_LINES__['/usr/local/lib/ruby/1.8/drb.rb']
 => ["require 'drb/drb'\n", "\n"]

WEIRD. What gives with the trailing underscores? It’s such a big constant that it leaves a two-character shadow!!

Note that $SAFE must be zero. See yycompile() in parse.y for details. But, yes, I saw this in PickAxe the Second.

The Ruby Mix Tape, Day Three #

by why in cult

I am making you guys cool! Except all today’s music is dorky. For computer nerds. Bummer.

Kid606 “Catstep / My Kitten / Catnip-Vatst”

Okay, so, hyperactive raver nerds. Hopping on the keyboards with pacifiers and bracelets and all that. And this is the computer singing astride that cat crawling back behind the monitor.

I just like where the computer goes to sing up high and it goes zhi-i-yipp!

Ratatat “Desert Eagle”

And these are the nerds who are still playing Contra on emulators or watching episodes of Arena, wherein Jim Kirk and the Gorn return to animalian instincts and brute manual fistclubbing.

It’s the music on Atari when California Games starts and a rainbow test pattern shows up behind the palm trees.

Hey, for connection details, see the very opening paragraph of Day One. The whole drb script you’re going to need so bad.