Pre Macro Implementation

This commit is contained in:
Stephan Rehfeld 2026-06-17 18:24:15 +02:00
parent 1b94f8ca7a
commit 4f762c7df9

View File

@ -46,14 +46,29 @@ where
}
}
/*
impl<T> Mul<Vector3<T>> for f64 {
type Output = Vector3<T>;
impl Mul<Vector3<f64>> for f64 {
type Output = Vector3<f64>;
fn mul(self, rhs: Vector3<T>) -> Self::Output {
fn mul(self, rhs: Vector3<f64>) -> Self::Output {
Vector3::new(self * rhs.x, self * rhs.y, self * rhs.z)
}
}*/
}
impl Mul<Vector3<f32>> for f32 {
type Output = Vector3<f32>;
fn mul(self, rhs: Vector3<f32>) -> Self::Output {
Vector3::new(self * rhs.x, self * rhs.y, self * rhs.z)
}
}
impl Mul<Vector3<i32>> for i32 {
type Output = Vector3<i32>;
fn mul(self, rhs: Vector3<i32>) -> Self::Output {
Vector3::new(self * rhs.x, self * rhs.y, self * rhs.z)
}
}
impl<T> Mul for Vector3<T>
where