emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Sweeter Emacs Lisp


From: Dmitry Gutov
Subject: Re: Sweeter Emacs Lisp
Date: Wed, 17 Jul 2013 19:07:51 +0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (windows-nt)

Lars Magne Ingebrigtsen <address@hidden> writes:

> I've never understood what people mean by "reading from the inside out".
> In C, that statement would have been
>
> upcase(replace_regexp_in_string("[<\\/> ]", "", car(tag)));
>
> Of course, if you've only programmed dotted languages like Java, you may
> have a problem.  (That goes without saying in any context, though.)

You know, Java also has method calls with implicit receiver (self).

> There's a cultural element, though.  C people have a tendency to assign
> values to variables more, so you get a more imperative style.

If a variable is assigned only once, it's not necessarily imperative
style. But yes, this is the tendency, and in this case, to follow the
control flow you can read the code from top to bottom, and the nested
calls, while common, are usually relatively simple.

> Yeah. that's pretty much incomprehensible and confirms my prejudices
> against the taste level of the Clojure people.  Are you sure they
> haven't managed to squeeze monads into the language, too?  For extra
> academic brownie points?

Only in contrib:
http://richhickey.github.io/clojure-contrib/monads-api.html

> I love how Emacs Lisp (and Common Lisp) eschew all these syntactical
> tricks.  They have dead simple syntaxes, and makes reading code clear
> and easy.  You get constructs that are unambiguous and general, even
> though they're somewhat longer than Perly stuff like the above.

I find that code rather readable and extensible enough (even when you
come back to it a few weeks later), and these would be the common
criticisms of Perl.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]