Provide a more informative internal error

original commit: 04e8e33313842d94d0cbff458ad23047ee1441fc
This commit is contained in:
Asumu Takikawa 2012-12-04 15:33:02 -05:00
parent a0c32ff288
commit 3ff53eb009

View File

@ -48,7 +48,13 @@
[#:F name (hash-ref subst name target)]
[#:arr dom rng rest drest kws
(cond
[(and (pair? drest) (ormap (and/c (cdr drest) (not/c bound-tvar?)) names)) =>
[(and (pair? drest)
(ormap (λ (name)
(and (equal? name (cdr drest))
(not (bound-tvar? name))
name))
names))
=>
(lambda (name)
(int-err "substitute used on ... variable ~a in type ~a" name target))]
[else