Skip to content

Issue 28157 bad semicolon #29215

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 24, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/doc/grammar.md
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ meta_seq : meta_item [ ',' meta_seq ] ? ;
## Statements

```antlr
stmt : decl_stmt | expr_stmt ;
stmt : decl_stmt | expr_stmt | ';' ;
```

### Declaration statements
Expand Down
2 changes: 1 addition & 1 deletion src/librustc/metadata/cstore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ impl CStore {
visit(cstore, dep, ordering);
}
ordering.push(cnum);
};
}
for (&num, _) in self.metas.borrow().iter() {
visit(self, num, &mut ordering);
}
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_trans/save/dump_csv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ macro_rules! down_cast_data {
data
} else {
$this.sess.span_bug($sp, &format!("unexpected data kind: {:?}", $id));
};
}
};
}

Expand Down
2 changes: 1 addition & 1 deletion src/librustc_trans/trans/debuginfo/metadata.rs
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ macro_rules! return_if_metadata_created_in_meantime {
.find_metadata_for_unique_id($unique_type_id) {
Some(metadata) => return MetadataCreationResult::new(metadata, true),
None => { /* proceed normally */ }
};
}
)
}

Expand Down
4 changes: 2 additions & 2 deletions src/librustdoc/passes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ pub fn strip_hidden(krate: clean::Crate) -> plugins::PluginResult {
let krate = {
struct Stripper<'a> {
stripped: &'a mut DefIdSet
};
}
impl<'a> fold::DocFolder for Stripper<'a> {
fn fold_item(&mut self, i: Item) -> Option<Item> {
if i.is_hidden_from_doc() {
Expand Down Expand Up @@ -60,7 +60,7 @@ pub fn strip_hidden(krate: clean::Crate) -> plugins::PluginResult {
let krate = {
struct ImplStripper<'a> {
stripped: &'a mut DefIdSet
};
}
impl<'a> fold::DocFolder for ImplStripper<'a> {
fn fold_item(&mut self, i: Item) -> Option<Item> {
if let clean::ImplItem(clean::Impl{
Expand Down
4 changes: 2 additions & 2 deletions src/libstd/sys/common/wtf8.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1019,7 +1019,7 @@ mod tests {
fn wtf8buf_from_iterator() {
fn f(values: &[u32]) -> Wtf8Buf {
values.iter().map(|&c| CodePoint::from_u32(c).unwrap()).collect::<Wtf8Buf>()
};
}
assert_eq!(f(&[0x61, 0xE9, 0x20, 0x1F4A9]).bytes, b"a\xC3\xA9 \xF0\x9F\x92\xA9");

assert_eq!(f(&[0xD83D, 0xDCA9]).bytes, b"\xF0\x9F\x92\xA9"); // Magic!
Expand All @@ -1038,7 +1038,7 @@ mod tests {
let mut string = initial.iter().map(c).collect::<Wtf8Buf>();
string.extend(extended.iter().map(c));
string
};
}

assert_eq!(e(&[0x61, 0xE9], &[0x20, 0x1F4A9]).bytes,
b"a\xC3\xA9 \xF0\x9F\x92\xA9");
Expand Down
2 changes: 1 addition & 1 deletion src/libterm/terminfo/searcher.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ fn test_get_dbpath_for_term() {
fn x(t: &str) -> String {
let p = get_dbpath_for_term(t).expect("no terminfo entry found");
p.to_str().unwrap().to_string()
};
}
assert!(x("screen") == "/usr/share/terminfo/s/screen");
assert!(get_dbpath_for_term("") == None);
env::set_var("TERMINFO_DIRS", ":");
Expand Down
2 changes: 1 addition & 1 deletion src/libtest/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -924,7 +924,7 @@ pub fn filter_tests(opts: &TestOpts, tests: Vec<TestDescAndFn>) -> Vec<TestDescA
} else {
None
}
};
}
filtered.into_iter().filter_map(filter).collect()
};

Expand Down