librustc: Remove all uses of "copy".

This commit is contained in:
Patrick Walton
2013-07-02 12:47:32 -07:00
parent b4e674f6e6
commit 99b33f7219
278 changed files with 3196 additions and 2610 deletions

View File

@@ -31,7 +31,7 @@ pub trait Pos {
}
/// A byte offset
#[deriving(Eq,IterBytes)]
#[deriving(Clone, Eq, IterBytes)]
pub struct BytePos(uint);
/// A character offset. Because of multibyte utf8 characters, a byte offset
/// is not equivalent to a character offset. The CodeMap will convert BytePos
@@ -96,15 +96,18 @@ are *absolute* positions from the beginning of the codemap, not positions
relative to FileMaps. Methods on the CodeMap can be used to relate spans back
to the original source.
*/
#[deriving(IterBytes)]
#[deriving(Clone, IterBytes)]
pub struct span {
lo: BytePos,
hi: BytePos,
expn_info: Option<@ExpnInfo>
}
#[deriving(Eq, Encodable, Decodable,IterBytes)]
pub struct spanned<T> { node: T, span: span }
#[deriving(Clone, Eq, Encodable, Decodable, IterBytes)]
pub struct spanned<T> {
node: T,
span: span,
}
impl cmp::Eq for span {
fn eq(&self, other: &span) -> bool {