diff --git a/collects/drscheme/private/module-language.ss b/collects/drscheme/private/module-language.ss index 6026d41dc1..a69f2e62c5 100644 --- a/collects/drscheme/private/module-language.ss +++ b/collects/drscheme/private/module-language.ss @@ -171,7 +171,20 @@ (compile-context-preservation-enabled (module-language-settings-full-trace? settings)) (when (module-language-settings-compilation-on? settings) + + (let ([annotations (drscheme:language:simple-settings-annotations settings)]) + (case annotations + [(none) + (use-compiled-file-paths + (cons (build-path "compiled" "drscheme") + (use-compiled-file-paths)))] + [(debug) + (use-compiled-file-paths + (cons (build-path "compiled" "drscheme" "errortrace") + (use-compiled-file-paths)))])) + (current-load/use-compiled (make-compilation-manager-load/use-compiled-handler)) + (manager-skip-file-handler (λ (p) ;; iterate over all of the collection paths; if we find that this path is diff --git a/collects/tests/drscheme/module-lang-test.ss b/collects/tests/drscheme/module-lang-test.ss index e2a034e6b4..300ef3cea7 100644 --- a/collects/tests/drscheme/module-lang-test.ss +++ b/collects/tests/drscheme/module-lang-test.ss @@ -3,6 +3,31 @@ (require "module-lang-test-utils.ss") (provide run-test) +(error #<<-- +need to add tests cases that check the value of the use-compiled-file handler: + +non-errortrace mode, saving compiled-files + +> (list (build-path "compiled" "drscheme") (build-path "compiled")) + +non-errortrace mode, not saving compiled files: + + the default, eg (list (build-path "compiled")) + +> >> errortrace mode, saving compiled files: +> >> +> >> (list (build-path "compiled" "drscheme" "errortrace") +> >> (build-path "compiled" "errortrace")) +> >> +> >> errortrace mode, not saving compiled files: +> >> +> >> (list (build-path "compiled" "errortrace")) +> >> +> >> And the two lists should also include (list (build-path +> >> "compiled")) at the end. +-- +) + ;; set up for tests that need external files (write-test-modules (module module-lang-test-tmp1 mzscheme