Skip to content

Commit

Permalink
style: Reformat the substitute_block function.
Browse files Browse the repository at this point in the history
  • Loading branch information
emilio committed Oct 4, 2017
1 parent c4dbbf0 commit 089d5ee
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions components/style/custom_properties.rs
Expand Up @@ -656,12 +656,15 @@ fn substitute_one(
///
/// Return `Err(())` if `input` is invalid at computed-value time.
/// or `Ok(last_token_type that was pushed to partial_computed_value)` otherwise.
fn substitute_block<'i, 't, F>(input: &mut Parser<'i, 't>,
position: &mut (SourcePosition, TokenSerializationType),
partial_computed_value: &mut ComputedValue,
substitute_one: &mut F)
-> Result<TokenSerializationType, ParseError<'i>>
where F: FnMut(&Name, &mut ComputedValue) -> Result<TokenSerializationType, ()> {
fn substitute_block<'i, 't, F>(
input: &mut Parser<'i, 't>,
position: &mut (SourcePosition, TokenSerializationType),
partial_computed_value: &mut ComputedValue,
substitute_one: &mut F
) -> Result<TokenSerializationType, ParseError<'i>>
where
F: FnMut(&Name, &mut ComputedValue) -> Result<TokenSerializationType, ()>
{
let mut last_token_type = TokenSerializationType::nothing();
let mut set_position_at_next_iteration = false;
loop {
Expand Down

0 comments on commit 089d5ee

Please sign in to comment.