about summary refs log tree commit diff
path: root/tvix/eval/src/value/list.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/eval/src/value/list.rs')
-rw-r--r--tvix/eval/src/value/list.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/tvix/eval/src/value/list.rs b/tvix/eval/src/value/list.rs
index d13e220bbe64..66f7eb8108e9 100644
--- a/tvix/eval/src/value/list.rs
+++ b/tvix/eval/src/value/list.rs
@@ -49,6 +49,14 @@ mod arbitrary {
 }
 
 impl NixList {
+    pub fn new() -> Self {
+        Self(vec![])
+    }
+
+    pub fn push(&mut self, val: Value) {
+        self.0.push(val)
+    }
+
     pub fn concat(&self, other: &Self) -> Self {
         let mut ret = self.clone();
         ret.0.extend_from_slice(&other.0);