about summary refs log tree commit diff
path: root/tvix/eval/src/builtins
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/eval/src/builtins')
-rw-r--r--tvix/eval/src/builtins/mod.rs4
-rw-r--r--tvix/eval/src/builtins/versions.rs2
2 files changed, 3 insertions, 3 deletions
diff --git a/tvix/eval/src/builtins/mod.rs b/tvix/eval/src/builtins/mod.rs
index 80c1fac2c0e2..45630819e124 100644
--- a/tvix/eval/src/builtins/mod.rs
+++ b/tvix/eval/src/builtins/mod.rs
@@ -59,7 +59,7 @@ fn pure_builtins() -> Vec<Builtin> {
             |args, vm| arithmetic_op!(&*args[0].force(vm)?, &*args[1].force(vm)?, +),
         ),
         Builtin::new("abort", &[true], |args, _| {
-            return Err(ErrorKind::Abort(args[0].to_str()?.to_string()));
+            Err(ErrorKind::Abort(args[0].to_str()?.to_string()))
         }),
         Builtin::new("attrNames", &[true], |args, _| {
             let xs = args[0].to_attrs()?;
@@ -313,7 +313,7 @@ fn pure_builtins() -> Vec<Builtin> {
             }
         }),
         Builtin::new("throw", &[true], |args, _| {
-            return Err(ErrorKind::Throw(args[0].to_str()?.to_string()));
+            Err(ErrorKind::Throw(args[0].to_str()?.to_string()))
         }),
         // coerce_to_string forces for us
         Builtin::new("toString", &[false], |args, vm| {
diff --git a/tvix/eval/src/builtins/versions.rs b/tvix/eval/src/builtins/versions.rs
index 9da7b52ab15c..79fb82b868fb 100644
--- a/tvix/eval/src/builtins/versions.rs
+++ b/tvix/eval/src/builtins/versions.rs
@@ -18,7 +18,7 @@ impl PartialOrd for VersionPart<'_> {
 }
 
 impl Ord for VersionPart<'_> {
-    fn cmp(self: &Self, other: &Self) -> Ordering {
+    fn cmp(&self, other: &Self) -> Ordering {
         match (self, other) {
             (VersionPart::Number(s1), VersionPart::Number(s2)) => {
                 // Note: C++ Nix uses `int`, but probably doesn't make a difference