diff options
| author | Patrick Walton <pcwalton@mimiga.net> | 2012-08-27 17:49:35 -0700 |
|---|---|---|
| committer | Patrick Walton <pcwalton@mimiga.net> | 2012-08-27 17:49:35 -0700 |
| commit | ff513b1bcd0d872899b453cb3542e7a0924d5bde (patch) | |
| tree | c38e2cdfb96ff3be34ae0b74e8df94bec4bc18c0 /src/libcore/float.rs | |
| parent | f2dcd7663a976f02675c72561eb377ecc263bd9b (diff) | |
| download | rust-ff513b1bcd0d872899b453cb3542e7a0924d5bde.tar.gz rust-ff513b1bcd0d872899b453cb3542e7a0924d5bde.zip | |
libcore: Replace a bunch of "== None" with ".is_none()".
Generally, "== None" calls into the shape glue, and it's also more useful.
Diffstat (limited to 'src/libcore/float.rs')
| -rw-r--r-- | src/libcore/float.rs | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/libcore/float.rs b/src/libcore/float.rs index f71619337cb..a0929f57081 100644 --- a/src/libcore/float.rs +++ b/src/libcore/float.rs @@ -457,16 +457,16 @@ fn test_from_str() { None => fail } - assert from_str(~"") == None; - assert from_str(~"x") == None; - assert from_str(~" ") == None; - assert from_str(~" ") == None; - assert from_str(~"e") == None; - assert from_str(~"E") == None; - assert from_str(~"E1") == None; - assert from_str(~"1e1e1") == None; - assert from_str(~"1e1.1") == None; - assert from_str(~"1e1-1") == None; + assert from_str(~"").is_none(); + assert from_str(~"x").is_none(); + assert from_str(~" ").is_none(); + assert from_str(~" ").is_none(); + assert from_str(~"e").is_none(); + assert from_str(~"E").is_none(); + assert from_str(~"E1").is_none(); + assert from_str(~"1e1e1").is_none(); + assert from_str(~"1e1.1").is_none(); + assert from_str(~"1e1-1").is_none(); } #[test] |
