This commit is contained in:
Danny Yoo 2011-03-29 21:58:07 -04:00
parent a3d5ec0b86
commit 7a5a8311b9

View File

@ -763,7 +763,7 @@
(: extract-static-knowledge (Expression CompileTimeEnvironment -> (: extract-static-knowledge (Expression CompileTimeEnvironment ->
CompileTimeEnvironmentEntry)) CompileTimeEnvironmentEntry))
;; Statically determines what we know about exp, given the compile time environment. ;; Statically determines what we know about exp, given the compile time environment.
(define (extract-static-knowledge exp cenv) (define (extract-static-knowledge exp cenv)
(cond (cond
@ -774,9 +774,12 @@
[(and (LocalRef? exp) [(and (LocalRef? exp)
(not (LocalRef-unbox? exp))) (not (LocalRef-unbox? exp)))
(let ([entry (list-ref cenv (LocalRef-depth exp))]) (let ([entry (list-ref cenv (LocalRef-depth exp))])
(printf "~s\n" entry)
(cond (cond
[(StaticallyKnownLam? entry) [(StaticallyKnownLam? entry)
entry] entry]
[(Const? entry)
entry]
[else [else
'?]))] '?]))]
[(ToplevelRef? exp) [(ToplevelRef? exp)