* Embedded sequence element expression in string template
@ 2014-09-15 12:34 Ito Kazumitsu
2014-09-16 1:31 ` Per Bothner
0 siblings, 1 reply; 2+ messages in thread
From: Ito Kazumitsu @ 2014-09-15 12:34 UTC (permalink / raw)
To: kawa
Is this correct?
#|kawa:1|# (scheme-implementation-version)
1.14.1 (revision 8024)
#|kawa:2|# (define a '#("A" "B" "C"))
#|kawa:3|# &{&[(vector-ref a 1)]}
B
#|kawa:4|# &{&[(a 1)]}
1
#|kawa:5|#
I expect &{&[(a 1)]} to be "B".
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Embedded sequence element expression in string template
2014-09-15 12:34 Embedded sequence element expression in string template Ito Kazumitsu
@ 2014-09-16 1:31 ` Per Bothner
0 siblings, 0 replies; 2+ messages in thread
From: Per Bothner @ 2014-09-16 1:31 UTC (permalink / raw)
To: Ito Kazumitsu, kawa
On 09/15/2014 05:34 AM, Ito Kazumitsu wrote:
> #|kawa:2|# (define a '#("A" "B" "C"))
> #|kawa:3|# &{&[(vector-ref a 1)]}
> B
> #|kawa:4|# &{&[(a 1)]}
> 1
> #|kawa:5|#
>
> I expect &{&[(a 1)]} to be "B".
As would I. This turned out to a missing $splice$ in the literals
part of a syntax-rules rule implementing the $string$ expander.
Thus the pattern for handling splices matched, when it shouldn't have.
I checked in the fix, along with a simple test-case.
--
--Per Bothner
per@bothner.com http://per.bothner.com/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-09-16 1:31 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-15 12:34 Embedded sequence element expression in string template Ito Kazumitsu
2014-09-16 1:31 ` Per Bothner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).