[racket] Sweet expressions error? WAS Re: Sweet expressions; or making it easier to introduce Racket to me and my coworkers :-)

From: Grant Rettke (grettke at acm.org)
Date: Wed Jul 20 18:30:13 EDT 2011

On Wed, Jul 20, 2011 at 4:10 PM, Greg Hendershott
<greghendershott at gmail.com> wrote:
>> define factorial(n)
>>  if {n <= 1}
>>    1
>>    {n * factorial{n - 1}}
>
> Wouldn't it need to be something like:
>
> define( factorial(n)
>  if {n <= 1}
>   1
>   {n * factorial{n - 1}} )
>
> ?
>
> That is, `define' itself needs some sort of handling, whether sweet or sour?

I tried from the docs:

#lang planet asumu/sweet racket

printf("Hello")

and got the error:

application: bad syntax (illegal use of `.') in: (#<eof> . #<eof>)



Posted on the users mailing list.