Skip to content

Instantly share code, notes, and snippets.

@LeifAndersen
Last active January 22, 2018 20:49
Show Gist options
  • Save LeifAndersen/ab54e9ede832d94b6e4fc49dcb39e008 to your computer and use it in GitHub Desktop.
Save LeifAndersen/ab54e9ede832d94b6e4fc49dcb39e008 to your computer and use it in GitHub Desktop.
#lang racket
(require (for-syntax syntax/parse
racket/syntax
syntax/location))
(define-syntax (M stx)
(syntax-parse stx
[(_ body ...)
#:with racket/base (format-id stx "racket/base")
#`(module* foo racket/base
body ...)]))
(define-syntax (N stx)
(syntax-parse stx
[(_)
#'object%]))
(provide N)
(M (N))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment