In a recent entry on differences between Haskell and Lisp, one of the Lisp
community’s long-time members, Daniel Weinreb, asked about my stated aversion
to JVM-based languages for everyday computing (sometimes referred to as
“scripting”). Specifically, it was asked in relation to Clojure, and why I
hasn’t been immediately taken by that language – despite it’s having so many
features I respect and admire.
I wanted to respond to Daniel’s question in a separate blog entry, since this
topic has come up so often, it seems, and deserves thought. The JVM is a rich,
mature platform, and you get so much for free by designing new languages on
top of it. The point of debate is: what are the costs, and are they always
worth the asking price?
[...]
Someone recently asked what my issue was regarding the JVM, since at the moment it prevents me from falling too much in love with Clojure – a language with the double-benefits of functional programming, and Lisp syntax and macros. Well, below is my reason. These may not seem like much time in the scheme of things, but psychologically it builds [...]
As some one who has enjoyed the Lisp language (in several flavors) for about
15 years now, I wanted to express some of my reactions at recently discovering
Haskell, and why it has supplanted Lisp as the apple of my eye. Perhaps it
will encourage others to explore this strange, wonderful world, where it looks
like some pretty damn cool ideas are starting to peek over the horizon.
[...]
Following on my last entry, where I built a better pre-commit
hook to ensure
every commit in my Git history passed make check
with flying colors, I
realized something today about my good friend, rebase
.
[...]
Recently a friend turned me onto an interesting article about a problem I had
just recently discovered about Git and its pre-commit hook:
Committing in git with only some changes added to the staging area still
results in an “atomic” revision that may never have existed as a working copy
and may not work.
[...]
This has probably been written countless times before, but I found myself
needing it today and it was quick to write. It lets you read characters from a
char array in C++ via the istream interface:
#include "ptrstream.h"
int main() {
ptristream in("Hello, world!\n");
char buf[31];
in.getline(buf, 32);
std::cout << buf << std::endl;
}
Handy for if you don’t want std::istringstream
needlessly copying character
strings.
[...]