diff --git a/collects/framework/private/color.ss b/collects/framework/private/color.ss index ecdc15b3..72fd7dff 100644 --- a/collects/framework/private/color.ss +++ b/collects/framework/private/color.ss @@ -50,6 +50,10 @@ (define text-mixin (mixin (text:basic<%>) (-text<%>) + + ;; For profiling + (define time #f) + ;; ---------------------- Coloring modes ---------------------------- ;; The tokenizer is stopped. This is used by the surrogate to enter @@ -179,6 +183,7 @@ ;; Allow breaks while getting tokens (parameterize-break #t (get-token in))]) + ;(printf "~a~n" lexeme) ;; Also allow breaks while trying to enter the critical region: (semaphore-wait/enable-break mutex-lock) (unless (eq? 'eof type) @@ -290,6 +295,7 @@ (lambda (x) #f)) current-pos)) (set! up-to-date? #t) + ;(printf "~a~n" (- (current-milliseconds) time)) (semaphore-post mutex-lock) (thread-suspend (current-thread)))) (background-colorer)) @@ -316,6 +322,7 @@ (parameterize-break #f (set! background-thread (thread (lambda () (background-colorer-entry)))))) + ;(set! time (current-milliseconds)) (do-insert/delete start-pos 0))) ;; See docs