Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Clojure vs Racket

Name: Anonymous 2011-01-31 6:28

Is Clojure a better language than Racket?

Name: Anonymous 2011-01-31 7:36

>>6
(require mzlib/defmacro)

(defmacro aif (cond then else)
  `(let ((it ,cond))
     (if it ,then ,else)))


Or if that library didn't exist:

(define-syntax (defmacro stx)
  (syntax-case stx ()
    ((defmacro <name> <args> . <body>)
     #`(define-syntax (<name> stx)
         (syntax-case stx ()
           ((<name> . <<args>>)
            (datum->syntax
             #'<name>
             (apply
              (lambda <args> . <body>)
              (syntax->datum #'<<args>>)))))))))


Though neither solve the problem that defmacro is BROKEN AS FUCK.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List