about summary refs log tree commit diff
path: root/tvix/eval/src/builtins
diff options
context:
space:
mode:
authorAdam Joseph <adam@westernsemico.com>2023-12-12T11·01-0800
committerclbot <clbot@tvl.fyi>2023-12-12T17·21+0000
commit29464fc65be0fb98b1ee1592ef99ed102be0e073 (patch)
tree66472a6ba22a050c841f6a3715a752ce88862e90 /tvix/eval/src/builtins
parent012b44244bd75ad3480141debda6011370195c2b (diff)
fix(tvix/eval): propagate catchables through builtins.splitVersion r/7196
This fixes our implementation of builtins.splitVersion so it
propagates catchables like cppnix does.

Change-Id: Id5d83ea76229f8c8f202aa42353cb609e67de43f
Reviewed-on: https://cl.tvl.fyi/c/depot/+/10305
Autosubmit: Adam Joseph <adam@westernsemico.com>
Tested-by: BuildkiteCI
Reviewed-by: tazjin <tazjin@tvl.su>
Diffstat (limited to 'tvix/eval/src/builtins')
-rw-r--r--tvix/eval/src/builtins/mod.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/tvix/eval/src/builtins/mod.rs b/tvix/eval/src/builtins/mod.rs
index b7649e7995ed..d85d6567ea8a 100644
--- a/tvix/eval/src/builtins/mod.rs
+++ b/tvix/eval/src/builtins/mod.rs
@@ -931,6 +931,9 @@ mod pure_builtins {
 
     #[builtin("splitVersion")]
     async fn builtin_split_version(co: GenCo, s: Value) -> Result<Value, ErrorKind> {
+        if s.is_catchable() {
+            return Ok(s);
+        }
         let s = s.to_str()?;
         let s = VersionPartsIter::new(s.as_str());