On Nov 30, 2008, at 5:47 PM, Randall R Schulz wrote:
>
> On Sunday 30 November 2008 13:30, André Thieme wrote:
>> ...
>>
>> Although a standard reader macro for infix syntax would be a nice
>> thing to have in Clojure.
>> ...
>
> Am I the only person who thinks this is a dead-end proposal that
On Sunday 30 November 2008 13:30, André Thieme wrote:
> ...
>
> Although a standard reader macro for infix syntax would be a nice
> thing to have in Clojure.
> ...
Am I the only person who thinks this is a dead-end proposal that should
be dropped because our BDFL will simply not consider it?
Ri
On 30 Nov., 20:09, Stuart Sierra <[EMAIL PROTECTED]> wrote:
> On Nov 28, 6:54 pm, Dmitri <[EMAIL PROTECTED]> wrote:
>
> > First of I'd like to say that I find Clojure to be an excellent
> > language, however I find the lack of infix operators makes reading
> > equations somewhat unnatural, eg:
>
>
On 30 Nov., 12:49, "Mark Volkmann" <[EMAIL PROTECTED]> wrote:
> On Sun, Nov 30, 2008 at 12:11 AM, Jeff Bester <[EMAIL PROTECTED]> wrote:
>
> > ;; used for order of evaluation table and for valid infix operators
> > (def +precedence+
> > {'rem 5,
> > '* 4,
> > '/ 3,
> > '+ 2,
> >
On Nov 28, 6:54 pm, Dmitri <[EMAIL PROTECTED]> wrote:
> First of I'd like to say that I find Clojure to be an excellent
> language, however I find the lack of infix operators makes reading
> equations somewhat unnatural, eg:
Hi, Dmitri,
Glad you like Clojure! There are Common Lisp packages like
On Sunday 30 November 2008 08:37, Dmitri wrote:
> I agree that the consistency that the s-expressions provide is
> valuable, and hence it would be counter productive to allow different
> kinds of syntax. However, it makes sense to have an explicit way to
> do infix notation.
That seems self-contr
I agree that the consistency that the s-expressions provide is
valuable, and hence it would be counter productive to allow different
kinds of syntax. However, it makes sense to have an explicit way to do
infix notation. As Johan points out above, Haskell has a very elegant
way of infixing function
On Sunday 30 November 2008 07:06, Daniel Renfer wrote:
> Since it's pretty much the topic, has anyone ever seen this:
>
> http://www.dwheeler.com/readable/
One thing I'll say is that I can't see myself _ever_ getting behind a
notation where white-space is significant. The so-called "semicolon
i
Since it's pretty much the topic, has anyone ever seen this:
http://www.dwheeler.com/readable/
On Sun, Nov 30, 2008 at 10:03 AM, Dmitri <[EMAIL PROTECTED]> wrote:
>
> Thanks for the example, the macro is exactly the solution was looking
> for.
>
> On Nov 30, 1:11 am, Jeff Bester <[EMAIL PROTECTE
Thanks for the example, the macro is exactly the solution was looking
for.
On Nov 30, 1:11 am, Jeff Bester <[EMAIL PROTECTED]> wrote:
> On Nov 28, 11:11 pm, Dmitri <[EMAIL PROTECTED]> wrote:
>
> > Thanks for the comments, the prefix notation may indeed be something
> > that one gets used to. I fi
On Saturday 29 November 2008 22:11, Jeff Bester wrote:
> ...
>
> If you are translating formulas it might be worth investing the time
> to create a macro to convert from infix to prefix with precedence
> rules, as well as, creating new operators. I think Peter Norvig
> covers something akin to t
On Saturday 29 November 2008 22:33, Tom Faulhaber wrote:
> Bill,
>
> Actually, the original Unix shell was written in this fashion by
> Steve Bourne at Bell Labs.
Wow. That takes me back. I remember seeing that code once (I was at an
educational institution that had a full source license for Bel
Bill,
Actually, the original Unix shell was written in this fashion by Steve
Bourne at Bell Labs.
In those days, people thought the ability to do this sort of thing was
one of the advantages of the C preprocessor. It didn't take too long
for them to change their minds. :-)
At Harvard back in th
On Sun, Nov 30, 2008 at 12:11 AM, Jeff Bester <[EMAIL PROTECTED]> wrote:
snip
> ;; used for order of evaluation table and for valid infix operators
> (def +precedence+
> {'rem 5,
> '* 4,
> '/ 3,
> '+ 2,
> '- 1})
What's the significance of this map being named with a lead
As most people will tell you, the prefix notation is more natural in
Lisp-like languages. However, I sometimes wonder if adding a Haskell
infix operator (grave accent changes the argument order) could be a
good idea in some situations; for example (2 `+ 3) -> (+ 2 3).
On Nov 28, 3:54 pm, Dmitri <
On Nov 28, 11:11 pm, Dmitri <[EMAIL PROTECTED]> wrote:
> Thanks for the comments, the prefix notation may indeed be something
> that one gets used to. I find it just fine for most cases, just not
> for mathematical expressions. The example function was not meant as a
> complete solution, but rathe
Thanks for the comments, the prefix notation may indeed be something
that one gets used to. I find it just fine for most cases, just not
for mathematical expressions. The example function was not meant as a
complete solution, but rather as an example of how trivial it is to
switch between the two
On Friday 28 November 2008 15:54, Dmitri wrote:
> First of I'd like to say that I find Clojure to be an excellent
> language, however I find the lack of infix operators makes reading
> equations somewhat unnatural, eg:
>
> (+ (- (* x x) (* y y)) a)
Try this:
(+
(-
(* x x)
(* y y))
a)
I can understand how that might be attractive to someone accustomed to
a language that uses infix operators (as opposed to a Lisp), but I
wonder how many people with a few weeks of Lisp under their belt would
find the infix function worth the trouble.
This reminds me of when we introduced the C l
19 matches
Mail list logo