mirror of
https://github.com/hannobraun/Fornjot
synced 2025-02-13 02:35:53 +00:00
Simplify
This commit is contained in:
parent
796fc796b7
commit
464fcdf664
@ -44,14 +44,9 @@ pub struct Triangle {
|
||||
pub vertices: [Vertex; 3],
|
||||
}
|
||||
|
||||
impl<V> From<[V; 3]> for Triangle
|
||||
where
|
||||
V: Into<Vertex>,
|
||||
{
|
||||
fn from(vertices: [V; 3]) -> Self {
|
||||
Self {
|
||||
vertices: vertices.map(Into::into),
|
||||
}
|
||||
impl From<[Vertex; 3]> for Triangle {
|
||||
fn from(vertices: [Vertex; 3]) -> Self {
|
||||
Self { vertices }
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user