Throw a proper syntax error on uses of the ffi `->'.

Closes PR 11421
This commit is contained in:
Eli Barzilay 2010-11-11 13:39:49 -05:00
parent 32de59e0c1
commit 735c4deac7

View File

@ -472,9 +472,8 @@
;; Also, see below for custom function types. ;; Also, see below for custom function types.
(provide ->) ; to signal better errors when trying to use this with contracts (provide ->) ; to signal better errors when trying to use this with contracts
(define-syntax -> (define-syntax (-> stx)
(syntax-id-rules () (raise-syntax-error '-> "should be used only in a _fun context" stx))
[_ (raise-syntax-error '-> "should be used only in a _fun context")]))
(provide _fun) (provide _fun)
(define-for-syntax _fun-keywords (define-for-syntax _fun-keywords