[PATCH] Add syntax/syntax library
(aliases for syntax/stx functions with contracts)
---
collects/syntax/syntax.rkt | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
create mode 100644 collects/syntax/syntax.rkt
diff --git a/collects/syntax/syntax.rkt b/collects/syntax/syntax.rkt
new file mode 100644
index 0000000..73261b7
--- /dev/null
+++ b/collects/syntax/syntax.rkt
@@ -0,0 +1,24 @@
+#lang racket/base
+
+;; syntax utilities
+
+(require
+ racket/contract/base
+ (rename-in syntax/stx
+ [stx-null? syntax-null?]
+ [stx-pair? syntax-pair?]
+ [stx-list? syntax-list?]
+ [stx-car syntax-car]
+ [stx-cdr syntax-cdr]
+ [stx->list syntax->list]
+ [stx-map syntax-map]))
+
+(provide/contract
+ [syntax-null? (-> any/c boolean?)]
+ [syntax-pair? (-> any/c boolean?)]
+ [syntax-list? (-> any/c boolean?)]
+ [syntax-car (-> syntax-pair? any)]
+ [syntax-cdr (-> syntax-pair? any)]
+ [syntax->list (-> syntax-list? (or/c list? #f))]
+ [syntax-map (->* (procedure?) #:rest syntax-list? any)]
+ [module-or-top-identifier=? (-> identifier? identifier? boolean?)])
\ No newline at end of file
--
1.7.10
--eRtJSFbw+EEWtPj3--