[Top][All Lists]

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

[Chicken-users] Macros not found when using eval

From: mel aise
Subject: [Chicken-users] Macros not found when using eval
Date: Sun, 13 Aug 2017 17:32:18 -0500

I'm having some trouble with the following program:

(define-syntax kons          
  (syntax-rules ()
    ((_ a b)
      (cons a b))))

(display (kons 1 '(2 3)))
(display (eval '(kons 1 '(2 3))))

(It's a contrived example but gets to whats going on haha)
When run with csi everything works fine,
but when compiled and then run, 'eval' throws an unbound variable error 

I may be missing something but is there a way to let 'eval' find syntax that has been defined?
I'm also having a similar issue with 'use'ing a module and 'eval' not being able to find procedures defined in that module

reply via email to

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