Parser - Removed unused code
This commit is contained in:
parent
c36654fb7e
commit
c5c8b04355
1 changed files with 0 additions and 12 deletions
|
@ -624,18 +624,6 @@ impl Parser {
|
|||
&self.tokens[self.current - 1]
|
||||
}
|
||||
|
||||
/// Execute some code while setting the loop state. Once the function
|
||||
/// is done running, remove the loop state.
|
||||
fn with_loop_state<F, T>(&mut self, loop_state: LoopParsingState, mut function: F) -> T
|
||||
where
|
||||
F: FnMut() -> T,
|
||||
{
|
||||
self.loop_state.push(loop_state);
|
||||
let result = function();
|
||||
self.loop_state.pop();
|
||||
result
|
||||
}
|
||||
|
||||
/// Take a peek at the current loop state.
|
||||
fn loop_state(&self) -> &LoopParsingState {
|
||||
&self.loop_state[self.loop_state.len() - 1]
|
||||
|
|
Loading…
Reference in a new issue