Email list hosting service & mailing list manager

Problem of implicit quasiquote Shiro Kawai (27 Jun 2020 18:08 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (27 Jun 2020 20:54 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 02:09 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 02:10 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (28 Jun 2020 08:14 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 09:34 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (28 Jun 2020 10:34 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 11:00 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 11:16 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (28 Jun 2020 12:50 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 20:45 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (28 Jun 2020 21:01 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 21:08 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (28 Jun 2020 21:14 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 21:42 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (28 Jun 2020 21:52 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (29 Jun 2020 06:31 UTC)
Re: Problem of implicit quasiquote Shiro Kawai (29 Jun 2020 20:27 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (30 Jun 2020 13:11 UTC)
Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen (04 Jul 2020 09:09 UTC)

Re: Problem of implicit quasiquote Marc Nieper-Wißkirchen 28 Jun 2020 21:01 UTC

Am So., 28. Juni 2020 um 22:45 Uhr schrieb Shiro Kawai <xxxxxx@gmail.com>:
>
> If you want such an extended case, another design choice(*) would be:
>
>  (case key
>     (`(a ,x) #t)
>     ...)

While this syntax is possible, it is not a natural extension to the
syntax of case, I think, because the R7RS version case already quotes
without any explicit (quasi)quote.

> Suppose if you want to generate
>    (case key ((a ,x) `(,x)))
> or
>    (case key (`(a ,x) `(,x)))
>
> With implicit quasiquote
>     `(case key ((a ,',x) `(,,'x)))     ;; need to use different order of unquote-quote before x
> explicit quasiquote
>     `(case key (`(a ,,'x) `(,,'x)))    ;; can consistently use unquote-unquote-quote
>
> I think the former is annoying, at least.   It's up to the macro designer, but if I'm the one to decide, I'd pair up quasiquote and unquote.

I agree that the qq engine is better tailored to outputting the second
syntax. But this is only relevant for macros that want to expand into
this hypothetical version of case. And then only for macros using qq
for output, which is not the best choice anyway.

> Footnote: (case key (`x #t)) would be confusing but should be interpreted as key being checked with quasiquote or x.  The same confusing pattern arises in the implicit version as well, namely (case key (,x #t)).

Yes, one would have to look carefully.