Skip to content

Commit

Permalink
Merge pull request #144 from brauliobz/extern_crates
Browse files Browse the repository at this point in the history
Extern crate grammar
  • Loading branch information
Havvy authored Oct 16, 2017
2 parents 796eeab + 976bc12 commit e17efcb
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/items/extern-crates.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Extern crate declarations

> **<sup>Syntax:<sup>**
> _ExternCrate_ :
> &nbsp;&nbsp; `extern` `crate` [IDENTIFIER]&nbsp;(`as` [IDENTIFIER])<sup>?</sup> `;`
An _`extern crate` declaration_ specifies a dependency on an external crate.
The external crate is then bound into the declaring scope as the `ident`
provided in the `extern_crate_decl`.
Expand Down Expand Up @@ -35,3 +39,5 @@ extern crate hello_world; // hyphen replaced with an underscore
```

[RFC 940]: https://github.com/rust-lang/rfcs/blob/master/text/0940-hyphens-considered-harmful.md

[IDENTIFIER]: identifiers.html

0 comments on commit e17efcb

Please sign in to comment.