[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lightweight syntax: a dissident view
- From: Pierre-Yves Gérardy <pygy79@...>
- Date: Fri, 26 Nov 2010 22:46:32 +0100
One more variation for the road:
[: arglist | explist :]
[: arglist : statements | explist :]
Thats how I like my functions: symmetric, with familiar special
characters and guarded by smiling borgs :-].
I said that in jest, but there has been a lot of research on the
effect of subliminal exposure to smiling faces (see [1-3]).
compare
[: arglist | explist :]
with
:[ arglist | explist ]:
The problem is that a happy mood, while improving the performances in
creative tasks, is derogatory to analytical problem solving (see
[4,5]). What about a neutral syntax (without comas in the arglist,
thay are not necessary)?
|: x y | explist :|
|: a b c : statements | explist :|
BTW, there was a mistake in the proposed compilation of the outer
return statement:
function foo()
local bar = |:: return "whatever"|
return bar
end
becomes
function foo()
local _R = true
local bar = |::
if _R then
_R = nil
return "whatever"
else
error()
end
:|
_R = nil
return bar
end
-- Pierre-Yves
1. http://psihologija.ffzg.hr/uploads/or/XT/orXTM_yBsRKas9LMIG3ZEw/Monahan2000mereexposure.pdf
2. http://www.psy.ucsd.edu/~dhuber/murphy_zajonc_1993.pdf
3. http://arno.unimaas.nl/show.cgi?fid=2436
4. http://books.google.be/books?hl=en&lr=&id=kB19aJKJLoEC&oi=fnd&pg=PA288&ots=trpv7r4C8u&sig=SSW6EgasZeItzcTqMKLJ20rx8x8#v=onepage&q&f=false
5. http://books.google.be/books?hl=en&lr=&id=LwVF17_xtPEC&oi=fnd&pg=PA55&ots=CcT2rUVYTw&sig=oF6Znt4vkL53KBHiDwlNN6yrm-c#v=onepage&q&f=false
- References:
- Re: Re: Re: Lightweight syntax: a dissident view, Gunnar Zötl
- Re: Re: Re: Lightweight syntax: a dissident view, Luis Carvalho
- Re: Re: Re: Lightweight syntax: a dissident view, Axel Kittenberger
- Re: Re: Re: Lightweight syntax: a dissident view, Pierre-Yves Gérardy
- Re: Re: Re: Lightweight syntax: a dissident view, Roberto Ierusalimschy
- Re: Re: Re: Lightweight syntax: a dissident view, Mateusz Czaplinski
- Re: Re: Re: Lightweight syntax: a dissident view, Axel Kittenberger
- Re: Lightweight syntax: a dissident view, Philippe Lhoste
- Re: Lightweight syntax: a dissident view, Pierre-Yves Gérardy
- Re: Lightweight syntax: a dissident view, Mark Hamburg
- Re: Lightweight syntax: a dissident view, Pierre-Yves Gérardy
- Re: Lightweight syntax: a dissident view, Pierre-Yves Gérardy
- Re: Lightweight syntax: a dissident view, Axel Kittenberger
- Re: Lightweight syntax: a dissident view, steve donovan
- Re: Lightweight syntax: a dissident view, phlnc8
- Re: Lightweight syntax: a dissident view, Erik Lindroos
- Re: Lightweight syntax: a dissident view, phlnc8
- Re: Lightweight syntax: a dissident view, Mark Hamburg
- Re: Lightweight syntax: a dissident view, Pierre-Yves Gérardy