One of the neatest bits of JRuby is the simple way you can call out to
Java. There's a
lot of Java out there, and you can wrap it up in nice little Ruby interfaces
with just a few lines of code.
Let's illustrate with some trivial examples, hooking up bits of Java to Ruby
and seeing how well they perform compared to the equivalent pure Ruby.
I've been doing a fair bit of Rust lately.
Honestly, I haven't been so smitten with a language since I started writing Ruby
back in 1999.
Rust is many of the things Ruby isn't—precompiled, screaming fast,
meticulously efficient, static, explicit, type-safe. But it's also expressive
and, above all, fun.
I think this rare mix makes it a good companion language for Ruby developers,
particularly with things like Helix and rutie making it easy to
bridge the two.
The best way of learning is by doing, so why not avoid that and just read about
me doing something instead?
Hmm, I'm doing this again, am I?
Last time was a custom PHP CMS with enough fancy features it even had dual-mode
HTML/XHTML rendering based on the
Accept-Content header. Look. It made sense at the time. Sort of. Shut up.
16(!) years later... it still mostly works, and it's certainly not the worst
thing I've ever written, but I haven't been a PHP guy in a long time, and it's
time for a change.
So here I am with Gutenberg, a static site
generator written in my new favourite language, Rust. Whether or not I actually
do anything with it, I helped
fix bugs in
projects in the process of
setting it up, and made a FreeBSD port, so it's already paid off in my book.