From 6baef71d57af67f230a0f8efb23fb2d7294f1e9c Mon Sep 17 00:00:00 2001 From: Sam Tobin-Hochstadt Date: Mon, 10 May 2010 16:09:47 -0400 Subject: [PATCH] don't add to identifiers --- collects/typed-scheme/typecheck/tc-subst.rkt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/collects/typed-scheme/typecheck/tc-subst.rkt b/collects/typed-scheme/typecheck/tc-subst.rkt index 765536ecdd..edd8fdc6d4 100644 --- a/collects/typed-scheme/typecheck/tc-subst.rkt +++ b/collects/typed-scheme/typecheck/tc-subst.rkt @@ -43,7 +43,7 @@ ;; here we have to increment the count for the domain, where the new bindings are in scope (let* ([arg-count (+ (length dom) (if rest 1 0) (if drest 1 0) (length kws))] [st* (if (integer? k) - (λ (t) (subst-type t (+ arg-count k) o polarity)) + (λ (t) (subst-type t (if (number? k) (+ arg-count k) k) o polarity)) st)]) (make-arr (map st dom) (st* rng) @@ -126,7 +126,7 @@ [#:arr dom rng rest drest kws ;; here we have to increment the count for the domain, where the new bindings are in scope (let* ([arg-count (+ (length dom) (if rest 1 0) (if drest 1 0) (length kws))] - [st* (lambda (t) (index-free-in? (+ arg-count k) t))]) + [st* (lambda (t) (index-free-in? (if (number? k) (+ arg-count k) k) t))]) (for-each for-type dom) (st* rng) (and rest (for-type rest))