You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
sugar/debug.rkt

17 lines
376 B
Racket

#lang racket/base
(provide report describe)
; report the current value of the variable, then return it
(define-syntax-rule (report var)
(begin
(basic-message 'var "=" var)
var))
(require (prefix-in williams: (planet williams/describe/describe)))
(define (describe x)
(parameterize ([current-output-port (current-error-port)])
(williams:describe x))
x)