refactor(tvix/eval): don't unnecessarily force in toString
Change-Id: I2bcc720ce7b6aa67ea5f145b1f2381a3ae833ac5 Reviewed-on: https://cl.tvl.fyi/c/depot/+/6691 Autosubmit: sterni <sternenseemann@systemli.org> Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
This commit is contained in:
parent
6576c2f15f
commit
a01524823a
1 changed files with 2 additions and 1 deletions
|
@ -238,7 +238,8 @@ fn pure_builtins() -> Vec<Builtin> {
|
|||
args.pop().unwrap().to_str()?.as_str().to_owned(),
|
||||
));
|
||||
}),
|
||||
Builtin::new("toString", &[true], |args, vm| {
|
||||
// coerce_to_string forces for us
|
||||
Builtin::new("toString", &[false], |args, vm| {
|
||||
args[0]
|
||||
.coerce_to_string(CoercionKind::Strong, vm)
|
||||
.map(Value::String)
|
||||
|
|
Loading…
Reference in a new issue