add a contract to places that use the #:kind argument (including defthing)
closes #259
This commit is contained in:
parent
a8813aa510
commit
5415cca336
|
@ -17,6 +17,7 @@
|
||||||
"on-demand.rkt"
|
"on-demand.rkt"
|
||||||
scheme/string
|
scheme/string
|
||||||
scheme/list
|
scheme/list
|
||||||
|
racket/contract
|
||||||
(for-syntax racket/base
|
(for-syntax racket/base
|
||||||
syntax/parse)
|
syntax/parse)
|
||||||
(for-label racket/base
|
(for-label racket/base
|
||||||
|
@ -127,9 +128,11 @@
|
||||||
|
|
||||||
(begin-for-syntax
|
(begin-for-syntax
|
||||||
(define-splicing-syntax-class kind-kw
|
(define-splicing-syntax-class kind-kw
|
||||||
|
#:attributes (kind) ;; Expr[String/#f]
|
||||||
#:description "#:kind keyword"
|
#:description "#:kind keyword"
|
||||||
(pattern (~optional (~seq #:kind kind)
|
(pattern (~optional (~seq #:kind k))
|
||||||
#:defaults ([kind #'#f]))))
|
#:declare k (expr/c #'(or/c string? #f) #:name "#:kind argument")
|
||||||
|
#:with kind #'(~? k.c #f)))
|
||||||
|
|
||||||
(define-splicing-syntax-class value-kw
|
(define-splicing-syntax-class value-kw
|
||||||
#:description "#:value keyword"
|
#:description "#:value keyword"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user