diff options
author | Joe Wilm <joe@jwilm.com> | 2016-09-18 11:19:57 -0700 |
---|---|---|
committer | Joe Wilm <joe@jwilm.com> | 2016-09-18 11:19:57 -0700 |
commit | a15a9c3cf75fe08abdd4c7572e49a3daf6680064 (patch) | |
tree | fde8b3ffd93c3c556c34047c1bb35a97722c0b44 | |
parent | edcb3d6defc69413f6b81a8c56be4ffbd638563d (diff) | |
download | r-alacritty-vte-a15a9c3cf75fe08abdd4c7572e49a3daf6680064.tar.gz r-alacritty-vte-a15a9c3cf75fe08abdd4c7572e49a3daf6680064.tar.bz2 r-alacritty-vte-a15a9c3cf75fe08abdd4c7572e49a3daf6680064.zip |
Add inline attributes to vte stuff
-rw-r--r-- | src/lib.rs | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -95,10 +95,12 @@ impl Parser { } } + #[inline] fn params(&self) -> &[i64] { &self.params[..self.num_params] } + #[inline] fn intermediates(&self) -> &[u8] { &self.intermediates[..self.intermediate_idx] } @@ -108,6 +110,7 @@ impl Parser { /// Requires a [`Perform`] in case `byte` triggers an action /// /// [`Perform`]: trait.Perform.html + #[inline] pub fn advance<P: Perform>(&mut self, performer: &mut P, byte: u8) { // Utf8 characters are handled out-of-band. if let State::Utf8 = self.state { @@ -138,6 +141,7 @@ impl Parser { utf8_parser.advance(&mut receiver, byte); } + #[inline] fn perform_state_change<P>(&mut self, performer: &mut P, state: State, action: Action, byte: u8) where P: Perform { @@ -174,6 +178,7 @@ impl Parser { } } + #[inline] fn perform_action<P: Perform>(&mut self, performer: &mut P, action: Action, byte: u8) { match action { Action::Print => performer.print(byte as char), |