This website requires JavaScript.
Explore
Help
Register
Sign In
mikros
/
rust
Watch
1
Star
0
Fork
0
You've already forked rust
Code
Issues
Pull Requests
Packages
Projects
Releases
Wiki
Activity
9fed2d587c
rust
/
src
/
test
/
ui
/
parser
/
duplicate-visibility.rs
5 lines
105 B
Rust
Raw
Normal View
History
Unescape
Escape
parser: merge `fn` grammars wrt. bodies & headers also refactor `FnKind` and `visit_assoc_item` visitors
2020-01-29 17:18:54 -06:00
// error-pattern: expected one of `(`, `async`, `const`, `extern`, `fn`
libsyntax: refactor the parser to consider foreign items as items parse_item_or_view_item() would drop visibility if none of the conditions following it would hold. This was the case when parsing extern {} blocks, where the function was only used to parse view items, but discarded the visibility of the first not-view item.
2012-10-09 04:59:03 -05:00
extern
{
pub
pub
fn
foo
(
)
;
}
Reference in New Issue
Copy Permalink