[lexer] Obey Rust book recommendation about order of leading lines
This commit is contained in:
		
							parent
							
								
									0ed4aa3ae5
								
							
						
					
					
						commit
						d69c3dbc31
					
				
					 3 changed files with 7 additions and 7 deletions
				
			
		|  | @ -2,6 +2,9 @@ | |||
|  * Eryn Wells <eryn@erynwells.me> | ||||
|  */ | ||||
| 
 | ||||
| use std::iter::Peekable; | ||||
| use states::*; | ||||
| 
 | ||||
| mod chars; | ||||
| mod error; | ||||
| mod states; | ||||
|  | @ -10,9 +13,6 @@ mod token; | |||
| pub use error::Error; | ||||
| pub use token::{Lex, Token}; | ||||
| 
 | ||||
| use std::iter::Peekable; | ||||
| use states::*; | ||||
| 
 | ||||
| pub type Result = std::result::Result<Lex, Error>; | ||||
| 
 | ||||
| pub struct Lexer<T> where T: Iterator<Item=char> { | ||||
|  |  | |||
|  | @ -4,8 +4,8 @@ | |||
| 
 | ||||
| extern crate sibillexer; | ||||
| 
 | ||||
| use std::io::prelude::*; | ||||
| use std::io; | ||||
| use std::io::Write; | ||||
| use sibillexer::Lexer; | ||||
| 
 | ||||
| fn main() { | ||||
|  |  | |||
|  | @ -2,15 +2,15 @@ | |||
|  * Eryn Wells <eryn@erynwells.me> | ||||
|  */ | ||||
| 
 | ||||
| use std::fmt::Debug; | ||||
| use token::Token; | ||||
| 
 | ||||
| mod begin; | ||||
| mod hash; | ||||
| mod id; | ||||
| 
 | ||||
| pub use self::begin::Begin; | ||||
| 
 | ||||
| use std::fmt::Debug; | ||||
| use token::Token; | ||||
| 
 | ||||
| #[derive(Debug)] | ||||
| pub enum StateResult { | ||||
|     /// Consume the character, remain on this state.
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue