Add manual &self/ and &static/ and /&self declarations that
are currently inferred. New rules are coming that will require them to be explicit. All add some explicit self declarations.
This commit is contained in:
parent
876b6ba792
commit
3168fe06ff
122 changed files with 509 additions and 477 deletions
|
@ -749,14 +749,14 @@ pub fn from_str(s: &str) -> Result<Json, Error> {
|
|||
|
||||
pub struct Decoder {
|
||||
priv json: Json,
|
||||
priv mut stack: ~[&Json],
|
||||
priv mut stack: ~[&self/Json],
|
||||
}
|
||||
|
||||
pub fn Decoder(json: Json) -> Decoder {
|
||||
Decoder { json: json, stack: ~[] }
|
||||
}
|
||||
|
||||
priv impl Decoder {
|
||||
priv impl Decoder/&self {
|
||||
fn peek(&self) -> &self/Json {
|
||||
if self.stack.len() == 0 { self.stack.push(&self.json); }
|
||||
self.stack[self.stack.len() - 1]
|
||||
|
@ -768,7 +768,7 @@ priv impl Decoder {
|
|||
}
|
||||
}
|
||||
|
||||
impl serialize::Decoder for Decoder {
|
||||
impl serialize::Decoder for Decoder/&self {
|
||||
fn read_nil(&self) -> () {
|
||||
debug!("read_nil");
|
||||
match *self.pop() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue