diff options
| author | Jihyun Yu <jihyun@nclab.kaist.ac.kr> | 2013-03-02 12:57:05 +0900 |
|---|---|---|
| committer | Jihyun Yu <jihyun@nclab.kaist.ac.kr> | 2013-03-02 12:57:05 +0900 |
| commit | 95bc9ea26df56b29f74583317ab080fdc7b99757 (patch) | |
| tree | 5bc88308814e2b0013f886efa2deaa7b56c5c8e5 /src/libcore/ptr.rs | |
| parent | 0fd1b58f236b4fe653d164836e94feebb2972931 (diff) | |
| download | rust-95bc9ea26df56b29f74583317ab080fdc7b99757.tar.gz rust-95bc9ea26df56b29f74583317ab080fdc7b99757.zip | |
Remove REC, change related tests/docs
Diffstat (limited to 'src/libcore/ptr.rs')
| -rw-r--r-- | src/libcore/ptr.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libcore/ptr.rs b/src/libcore/ptr.rs index 2266c2511f8..ca5f6671130 100644 --- a/src/libcore/ptr.rs +++ b/src/libcore/ptr.rs @@ -1,4 +1,4 @@ -// Copyright 2012 The Rust Project Developers. See the COPYRIGHT +// Copyright 2012-2013 The Rust Project Developers. See the COPYRIGHT // file at the top-level directory of this distribution and at // http://rust-lang.org/COPYRIGHT. // @@ -300,7 +300,7 @@ impl<T:Ord> Ord for &const T { pub fn test() { unsafe { struct Pair {mut fst: int, mut snd: int}; - let mut p = Pair {mut fst: 10, mut snd: 20}; + let mut p = Pair {fst: 10, snd: 20}; let pptr: *mut Pair = &mut p; let iptr: *mut int = cast::reinterpret_cast(&pptr); assert (*iptr == 10);; @@ -308,7 +308,7 @@ pub fn test() { assert (*iptr == 30); assert (p.fst == 30);; - *pptr = Pair {mut fst: 50, mut snd: 60}; + *pptr = Pair {fst: 50, snd: 60}; assert (*iptr == 50); assert (p.fst == 50); assert (p.snd == 60); |
