From 536122e08066c762a0f6a1585c458f6c7a54bc2e Mon Sep 17 00:00:00 2001 From: zhguchev Date: Tue, 11 Jan 2022 14:56:26 +0100 Subject: add defaults for the several structs --- src/dynamics/joint/fixed_joint.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/dynamics/joint/fixed_joint.rs') diff --git a/src/dynamics/joint/fixed_joint.rs b/src/dynamics/joint/fixed_joint.rs index 10c4d7e..6082938 100644 --- a/src/dynamics/joint/fixed_joint.rs +++ b/src/dynamics/joint/fixed_joint.rs @@ -6,7 +6,11 @@ use crate::math::{Isometry, Point, Real}; pub struct FixedJoint { data: JointData, } - +impl Default for FixedJoint{ + fn default() -> Self { + FixedJoint::new() + } +} impl FixedJoint { pub fn new() -> Self { #[cfg(feature = "dim2")] -- cgit From 0c7ebae1aaae3ca2a55e33429a4466110deda208 Mon Sep 17 00:00:00 2001 From: Sébastien Crozet Date: Sun, 23 Jan 2022 18:04:24 +0100 Subject: Run cargo fmt --- src/dynamics/joint/fixed_joint.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/dynamics/joint/fixed_joint.rs') diff --git a/src/dynamics/joint/fixed_joint.rs b/src/dynamics/joint/fixed_joint.rs index 6082938..c7ca904 100644 --- a/src/dynamics/joint/fixed_joint.rs +++ b/src/dynamics/joint/fixed_joint.rs @@ -6,11 +6,13 @@ use crate::math::{Isometry, Point, Real}; pub struct FixedJoint { data: JointData, } -impl Default for FixedJoint{ + +impl Default for FixedJoint { fn default() -> Self { FixedJoint::new() } } + impl FixedJoint { pub fn new() -> Self { #[cfg(feature = "dim2")] -- cgit