<HTML><BODY>Thank you!<br><br>I thought, that #'(1 . (2)) == #'(1 2) as '(1 . (2)) == '(1 2)<br><br>And Racket printer thinks same:<br><br><p>> #'(1 . (2))<br>#<syntax:19:4 (1 2)></p><br>Fri, 15 Aug 2014 07:13:39 +0100 от Matthew Flatt <mflatt@cs.utah.edu>:<br>
<blockquote style="border-left:1px solid #0857A6; margin:10px; padding:0 0 0 10px;">
<div id="">
<div class="js-helper js-readmsg-msg">
<style type="text/css"></style>
<div>
<base target="_self" href="https://e.mail.ru/">
<div id="style_14080832300000000043_BODY">At Fri, 15 Aug 2014 09:55:11 +0400, Roman Klochkov wrote:<br>
> What is the difference?<br>
> <br>
> > (let ([stx #'(1 (+ 3 4) 5 6)]) (equal? (syntax->list stx) (syntax-e stx)))<br>
> #t Or syntax->list == (lambda (x) (let ([res (syntax-e x)]) (if (list? x) x <br>
> #f))) ?<br>
<br>
You need a `.` to expose the difference:<br>
<br>
> (syntax-e #'(1 . (2)))<br>
'(#<syntax::35 1> . #<syntax::39 (2)>)<br>
<br>
> (syntax->list #'(1 . (2)))<br>
'(#<syntax::62 1> #<syntax::67 2>)<br>
<br>
</div>
<base target="_self" href="https://e.mail.ru/">
</div>
</div>
</div>
</blockquote>
<br>
<br>-- <br>Roman Klochkov<br></BODY></HTML>