Skip to content
This repository has been archived by the owner. It is now read-only.
Browse files

style/imports: add example for import ordering

  • Loading branch information
nathantypanski committed Jun 30, 2014
1 parent 6cdc15b commit 11267f3b90372ae3b3d8ec7daa1030039a920048
Showing with 17 additions and 1 deletion.
  1. +17 −1 style/
@@ -8,7 +8,23 @@ sections, in order, with a blank space between each:
* local `use` imports
* `pub use` imports

> **[FIXME]** add example.
For example:

// Crates.
extern crate getopts;
extern crate mylib;
// Standard library imports.
use getopts::{optopt, getopts};
use std::os;
// Import from a library that we wrote.
use mylib::webserver;
// Will be reexported when we import this module.
pub use self::types::Webdata;

### Avoid `use *`, except in tests. [RFC]

0 comments on commit 11267f3

Please sign in to comment.