From 69458a138df3bbb9a3bef13ec33d070739a66ff7 Mon Sep 17 00:00:00 2001 From: Jeff Date: Fri, 15 Nov 2024 19:19:31 -0500 Subject: [PATCH] Clean up --- dust-lang/src/native_function/logic.rs | 2 +- dust-lang/src/value/mod.rs | 2 +- dust-lang/src/vm.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dust-lang/src/native_function/logic.rs b/dust-lang/src/native_function/logic.rs index e414743..95395c0 100644 --- a/dust-lang/src/native_function/logic.rs +++ b/dust-lang/src/native_function/logic.rs @@ -1,6 +1,6 @@ use std::io::{self, stdout, Write}; -use crate::{Instruction, NativeFunctionError, Span, Value, Vm, VmError}; +use crate::{Instruction, NativeFunctionError, Value, Vm, VmError}; pub fn panic(vm: &Vm, instruction: Instruction) -> Result, VmError> { let argument_count = instruction.c(); diff --git a/dust-lang/src/value/mod.rs b/dust-lang/src/value/mod.rs index 16848c2..5324d98 100644 --- a/dust-lang/src/value/mod.rs +++ b/dust-lang/src/value/mod.rs @@ -251,7 +251,7 @@ impl Clone for Value { Value::Function(function) => Value::Function(function.clone()), Value::Integer(integer) => Value::Integer(*integer), Value::List(list) => Value::List(list.clone()), - Value::Range(range) => Value::Range(range.clone()), + Value::Range(range) => Value::Range(*range), Value::String(string) => Value::String(string.clone()), } } diff --git a/dust-lang/src/vm.rs b/dust-lang/src/vm.rs index ce13c64..8f76371 100644 --- a/dust-lang/src/vm.rs +++ b/dust-lang/src/vm.rs @@ -616,7 +616,7 @@ impl<'a> Vm<'a> { } #[derive(Clone, Debug, PartialEq)] -enum Register { +pub enum Register { Empty, Value(Value), Pointer(Pointer),