diff options
| author | bors <bors@rust-lang.org> | 2014-05-14 19:31:52 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-05-14 19:31:52 -0700 |
| commit | e10fd317211511c3fb4656aee10eb4fd17dc8586 (patch) | |
| tree | 751c444f333d465d11aa20ae6bbd377755bf8aa3 /src/libnum/complex.rs | |
| parent | 2a7a39191a83fc2a63df6cb47acd344ae669d9c7 (diff) | |
| parent | 351a564df5d62175696a1f87c40629f212f1ee1e (diff) | |
| download | rust-e10fd317211511c3fb4656aee10eb4fd17dc8586.tar.gz rust-e10fd317211511c3fb4656aee10eb4fd17dc8586.zip | |
auto merge of #14170 : pcwalton/rust/detildestr-misclibs, r=alexcrichton
r? @brson
Diffstat (limited to 'src/libnum/complex.rs')
| -rw-r--r-- | src/libnum/complex.rs | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/libnum/complex.rs b/src/libnum/complex.rs index 3a666273d4a..b82c4d177ba 100644 --- a/src/libnum/complex.rs +++ b/src/libnum/complex.rs @@ -348,15 +348,15 @@ mod test { #[test] fn test_to_str() { - fn test(c : Complex64, s: ~str) { - assert_eq!(c.to_str(), s); + fn test(c : Complex64, s: StrBuf) { + assert_eq!(c.to_str().to_strbuf(), s); } - test(_0_0i, "0+0i".to_owned()); - test(_1_0i, "1+0i".to_owned()); - test(_0_1i, "0+1i".to_owned()); - test(_1_1i, "1+1i".to_owned()); - test(_neg1_1i, "-1+1i".to_owned()); - test(-_neg1_1i, "1-1i".to_owned()); - test(_05_05i, "0.5+0.5i".to_owned()); + test(_0_0i, "0+0i".to_strbuf()); + test(_1_0i, "1+0i".to_strbuf()); + test(_0_1i, "0+1i".to_strbuf()); + test(_1_1i, "1+1i".to_strbuf()); + test(_neg1_1i, "-1+1i".to_strbuf()); + test(-_neg1_1i, "1-1i".to_strbuf()); + test(_05_05i, "0.5+0.5i".to_strbuf()); } } |
