From: Bennet Bleßmann Date: Thu, 31 Jul 2025 19:38:26 +0000 (+0200) Subject: impl From rather than Into X-Git-Tag: v0.10.0~35^2~1^2~11 X-Git-Url: https://git.sagredo.dev/?a=commitdiff_plain;h=fae5e13bd51a1810e9f98bd88a1ed906e94cff20;p=scryer-prolog.git impl From rather than Into --- diff --git a/src/machine/machine_indices.rs b/src/machine/machine_indices.rs index 07d77f6a..3c918883 100644 --- a/src/machine/machine_indices.rs +++ b/src/machine/machine_indices.rs @@ -159,17 +159,17 @@ impl From for CodeIndex { } } -impl Into for CodeIndex { +impl From for CodeIndexOffset { #[inline(always)] - fn into(self) -> CodeIndexOffset { - self.0 + fn from(value: CodeIndex) -> CodeIndexOffset { + value.0 } } -impl Into for &'_ CodeIndex { +impl From<&'_ CodeIndex> for CodeIndexOffset { #[inline(always)] - fn into(self) -> CodeIndexOffset { - self.0 + fn from(value: &'_ CodeIndex) -> CodeIndexOffset { + value.0 } }