about summary refs log tree commit diff
path: root/src/libnum
diff options
context:
space:
mode:
authorEduard Burtescu <edy.burt@gmail.com>2014-03-06 19:24:11 +0200
committerEduard Burtescu <edy.burt@gmail.com>2014-03-13 14:21:45 +0200
commit20b4e159edb54cecb8abdedb187ba05a869b3bf0 (patch)
treed473bd66612ad8d1f8849cd2dced63d5e4023dab /src/libnum
parentcdc18b96d6aa38c22b4fa9715c974ef986ad250d (diff)
Implement automatic overloaded dereference.
Closes #7141.
Diffstat (limited to 'src/libnum')
-rw-r--r--src/libnum/complex.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libnum/complex.rs b/src/libnum/complex.rs
index 5ffd23aa346..b226e773dbb 100644
--- a/src/libnum/complex.rs
+++ b/src/libnum/complex.rs
@@ -101,7 +101,7 @@ impl<T: Clone + Float> Cmplx<T> {
     /// Convert a polar representation into a complex number.
     #[inline]
     pub fn from_polar(r: &T, theta: &T) -> Cmplx<T> {
-        Cmplx::new(r * theta.cos(), r * theta.sin())
+        Cmplx::new(*r * theta.cos(), *r * theta.sin())
     }
 }