Skip to content

Instantly share code, notes, and snippets.

@takikawa
Created July 26, 2012 06:21
lift a definition?
#lang racket
(module bar racket
(define-syntax (foo stx)
(syntax-case stx ()
[(_ x)
(begin (syntax-local-lift-module-end-declaration
#'(define/contract x integer? 5))
#'(void))]))
(foo x)
(provide x))
(require 'bar)
x
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment