pull/218/head
Matthew Butterick 4 years ago
parent c8c23a1d39
commit ea25058349

@ -1 +1 @@
1578951924 1580599066

@ -54,8 +54,12 @@
(for/fold ([usps null] (for/fold ([usps null]
[pcjs null]) [pcjs null])
([path (in-list source-paths-in)]) ([path (in-list source-paths-in)])
(match (with-handlers ([(λ (x) (eq? x 'cache-miss)) values]) (match (let/ec exit
(render-to-file-if-needed path #f #f (λ () (raise 'cache-miss)))) ;; todo: faster test
;; the problem with this test is that it's not cheap for uncached files:
;; it ultimatedly calls get-template-for,
;; which looks in metas, so the file ends up being compiled anyhow.
(render-to-file-if-needed path #f #f (λ () (exit 'cache-miss))))
['cache-miss (values (cons path usps) pcjs)] ['cache-miss (values (cons path usps) pcjs)]
[_ (values usps (cons (cons path #true) pcjs))]))) [_ (values usps (cons (cons path #true) pcjs))])))

Loading…
Cancel
Save