From 11e35a77a671b3d85ea161e1799ef3f6d98201f1 Mon Sep 17 00:00:00 2001 From: Adam Joseph Date: Tue, 12 Dec 2023 20:47:31 -0800 Subject: refactor(tvix/eval): let OpCoerceToString select the CoercionKind Change-Id: I92d58ef216d7e0766af70f019b3dcd445284a95d Reviewed-on: https://cl.tvl.fyi/c/depot/+/10344 Reviewed-by: tazjin Tested-by: BuildkiteCI --- tvix/eval/src/opcode.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'tvix/eval/src/opcode.rs') diff --git a/tvix/eval/src/opcode.rs b/tvix/eval/src/opcode.rs index b57a79a3baec..f89c1c12e7fd 100644 --- a/tvix/eval/src/opcode.rs +++ b/tvix/eval/src/opcode.rs @@ -201,10 +201,8 @@ pub enum OpCode { /// Interpolate the given number of string fragments into a single string. OpInterpolate(Count), - /// Force the Value on the stack and coerce it to a string, always using - /// `CoercionKind::Weak { import_paths: true }`. This is the behavior - /// necessary for path interpolation. - OpCoerceToString, + /// Force the Value on the stack and coerce it to a string + OpCoerceToString(crate::CoercionKind), // Paths /// Attempt to resolve the Value on the stack using the configured [`NixSearchPath`][] -- cgit 1.4.1