diff options
Diffstat (limited to '')
-rw-r--r-- | stdlib/source/library/lux/tool/compiler/meta/cache/module.lux | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/stdlib/source/library/lux/tool/compiler/meta/cache/module.lux b/stdlib/source/library/lux/tool/compiler/meta/cache/module.lux index 9a4ed2e1b..603aa2ffd 100644 --- a/stdlib/source/library/lux/tool/compiler/meta/cache/module.lux +++ b/stdlib/source/library/lux/tool/compiler/meta/cache/module.lux @@ -35,18 +35,18 @@ (def: .public (path fs context @module) (All (_ !) (-> (file.System !) Context module.ID file.Path)) (format (//.path fs context) - (# fs separator) + (at fs separator) (%.nat @module))) (def: .public (enabled? fs context @module) (All (_ !) (-> (file.System !) Context module.ID (! Bit))) - (# fs directory? (..path fs context @module))) + (at fs directory? (..path fs context @module))) (def: .public (enable! ! fs context @module) (All (_ !) (-> (Monad !) (file.System !) Context module.ID (! (Try Any)))) (do ! [.let [path (..path fs context @module)] - module_exists? (# fs directory? path)] + module_exists? (at fs directory? path)] (if module_exists? (in {try.#Success []}) (with_expansions [<failure> (exception.except ..cannot_enable [(//.path fs context) @@ -60,13 +60,13 @@ success (|> path - (# fs make_directory) - (# ! each (|>> (pipe.case - {try.#Failure error} - <failure> + (at fs make_directory) + (at ! each (|>> (pipe.case + {try.#Failure error} + <failure> - success - success)))))))))) + success + success)))))))))) (def: file file.Path @@ -75,28 +75,28 @@ (def: .public (descriptor fs context @module) (All (_ !) (-> (file.System !) Context module.ID file.Path)) (format (..path fs context @module) - (# fs separator) + (at fs separator) ..file)) (def: .public (cache! fs context @module content) (All (_ !) (-> (file.System !) Context module.ID Binary (! (Try Any)))) - (# fs write (..descriptor fs context @module) content)) + (at fs write (..descriptor fs context @module) content)) (def: .public (cache fs context @module) (All (_ !) (-> (file.System !) Context module.ID (! (Try Binary)))) - (# fs read (..descriptor fs context @module))) + (at fs read (..descriptor fs context @module))) (def: .public (artifacts ! fs context @module) (All (_ !) (-> (Monad !) (file.System !) Context module.ID (! (Try (Dictionary Text Binary))))) (do [! (try.with !)] - [files (# fs directory_files (..path fs context @module)) + [files (at fs directory_files (..path fs context @module)) pairs (|> files (list#each (function (_ file) [(file.name fs file) file])) (list.only (|>> product.left (text#= ..file) not)) (monad.each ! (function (_ [name path]) (|> path - (# fs read) - (# ! each (|>> [name]))))))] + (at fs read) + (at ! each (|>> [name]))))))] (in (dictionary.of_list text.hash (for @.old (as (List [Text Binary]) pairs) pairs))))) |