Replace uint/int by usize/isize in various places.

This commit is contained in:
Ms2ger 2015-02-20 14:43:29 +01:00
parent 9c863a6bd4
commit 6d30ec77c8
14 changed files with 36 additions and 34 deletions

View file

@ -81,7 +81,7 @@ impl<'a> CharacterDataMethods for JSRef<'a, CharacterData> {
}
fn SubstringData(self, offset: u32, count: u32) -> Fallible<DOMString> {
Ok(self.data.borrow()[offset as uint .. count as uint].to_owned())
Ok(self.data.borrow()[offset as usize .. count as usize].to_owned())
}
fn AppendData(self, arg: DOMString) -> ErrorResult {
@ -107,9 +107,9 @@ impl<'a> CharacterDataMethods for JSRef<'a, CharacterData> {
} else {
count
};
let mut data = self.data.borrow()[..offset as uint].to_owned();
let mut data = self.data.borrow()[..offset as usize].to_owned();
data.push_str(arg.as_slice());
data.push_str(&self.data.borrow()[(offset + count) as uint..]);
data.push_str(&self.data.borrow()[(offset + count) as usize..]);
*self.data.borrow_mut() = data;
// FIXME: Once we have `Range`, we should implement step7 to step11
Ok(())