about summary refs log tree commit diff
path: root/tvix/eval/src/lib.rs
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2022-12-12T14·19+0300
committertazjin <tazjin@tvl.su>2022-12-21T22·37+0000
commit25fc6b7c25d75075461e7976b27b81ba6a8140fe (patch)
tree591e4bbec276ead8cbce0c847e79449733ca7ad1 /tvix/eval/src/lib.rs
parentbf286a54bc2ac5eeb78c3d5c5ae66e9af24d74d4 (diff)
feat(tvix/eval): introduce initial EvalIO trait r/5458
This trait is going to be used to abstract filesystem interactions in
Tvix.

For now, it only contains a `read_to_string` method that closely
mirrors `std::fs::read_to_string`.

As a first step, to see how this works in practice, we will thread
through only this function to the various relevant parts.

Two implementations are provided in tvix-eval itself: A dummy
implementation (which just returns ErrorKind::NotImplemented for all
operations), and a std implementation which delegates to `std`
functions.

Change-Id: Ied3e3bf4bd0e874dd84e166190e3873a0f923ddb
Reviewed-on: https://cl.tvl.fyi/c/depot/+/7565
Reviewed-by: grfn <grfn@gws.fyi>
Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/eval/src/lib.rs')
-rw-r--r--tvix/eval/src/lib.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/tvix/eval/src/lib.rs b/tvix/eval/src/lib.rs
index 4a5ae6f3e840..c9a6ac103eba 100644
--- a/tvix/eval/src/lib.rs
+++ b/tvix/eval/src/lib.rs
@@ -16,6 +16,7 @@ mod builtins;
 mod chunk;
 mod compiler;
 mod errors;
+mod io;
 pub mod observer;
 mod opcode;
 mod pretty_ast;