Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I read more about Lisp than I program in it, and I feel just like you about the language.

Everything looks the same. Some time ago I read that Common Lisp had multiple return values. I was expecting something like Lua, where a function like this:

function fn() return 1, 2, 3 end

Is called like this:

a, b, c = fn()

But in Lisp, it's just the same old

(some-magic-words-here (other-things) (other-things))

Could I have some commas and equals signs to separate things at least? :-(

Then I heard various Lisps have classes, structs, objects and what not. Does it look like this?

{ name: value, name: value }

Or this?

class Name { Type name; Type name; }

No...

It looks like this:

(def-something ((something-here)) (something-else) (((something-else-2))))

If you are lucky you have a few :keywords or &keywords so your eyes have something to hang onto. Other than that, everything looks so... positional, and a closing parenthesis could mean anything from the end of a simple expression like (+ 1 1) or the end of the declarative part and the start of the executable part of a complex structure.

You don't even need to go that far to find these problems: just look at:

(let ((new-var-2 value) (new-var-2 value)) (some-code-here))

(if (condition) (runs-if-true) (runs-if-false))

You'd better use a very consistent indentation, because there is almost no visual separation between the "runs-if-true" and "runs-if-false"!



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: