[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [ANN] metalua 0.4
- From: Fabien <fleutot+lua@...>
- Date: Thu, 7 Feb 2008 01:08:28 +0100
Does anybody take Arc seriously? I've seen nothing but derision for it
I think the design is really clean. There's no killer feature, so for a piece of software that's been touted as the Second Coming for as long we've been expected Duke Nukem Forever, people are disappointed, but I really find it tasteful, even if it still lacks most of the features required for a usable language.
Except for one point: he seems to consider that lack of outside macro hygiene is acceptable in a Lisp-1, and I find it even filthier than being a Lisp-2. It really puzzles me.
And then there's my fundamental issue with Lisp: its extreme flexibility and lack of syntactical guidelines don't encourage the writing of reusable libraries, so it's a fine tool when you plan to write everything from scratch, but you won't be able to stand on the shoulders of giants. Therefore for many purposes, Java is faster, thanks to the library code you don't have to write.
(Explanations:)
Lisp-2 are lisp dialects in which functions names are in a namespace distinct from other values. If Lua was a Lisp-2, the following piece of code would work, because type-the-value wouldn't shadow type-the-function:
do
local type = "punt!"
assert(type("foo")=="string")
end
Outside hygiene is the kind of problem you get when a variable you use in a macro changes its meaning at the place the macro is used. Here's a piece of incorrect metalua code failing because type is captured from outside:
-{ block:
require 'dollar'
function dollar.MUST_BE_STRING(x)
return +{ assert (type(-{x}) == "string" }
end }
do
local type ="punt!"
$MUST_BE_STRING("I am a string indeed")
end