chicken-janitors
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-janitors] [Chicken-bugs] #392: unquoted expressions in macros


From: Chicken Scheme
Subject: [Chicken-janitors] [Chicken-bugs] #392: unquoted expressions in macros
Date: Thu, 20 Dec 2007 00:52:15 -0000

#392: unquoted expressions in macros
----------------------+-----------------------------------------------------
 Reporter:  elf       |       Owner:     
     Type:  defect    |      Status:  new
 Priority:  critical  |   Milestone:     
Component:  compiler  |     Version:  2.7
 Keywords:  macro     |  
----------------------+-----------------------------------------------------
 all unquoted expressions in macros are ALWAYS evaluated.
 (define-macro (some-macro foo)
     `(case ,(cadr foo)
          ((1)  ,(set! foo 2))
          ((2)  ,(set! foo 3))))

 will always set foo to 3, even if cadr foo is 1.  this is clearly
 incorrect behaviour.

-- 
Ticket URL: <http://trac.callcc.org/ticket/392>
Chicken Scheme <http://www.call-with-current-continuation.org/>
The CHICKEN Scheme-to-C compiler

reply via email to

[Prev in Thread] Current Thread [Next in Thread]