Don't print additional spaces when pretty-printing NoDelim groups
This commit is contained in:
parent
5da0576d83
commit
c84402872e
3 changed files with 2 additions and 4 deletions
|
@ -245,7 +245,7 @@ fn token_kind_to_string_ext(tok: &TokenKind, convert_dollar_crate: Option<Span>)
|
|||
token::CloseDelim(token::Bracket) => "]".to_string(),
|
||||
token::OpenDelim(token::Brace) => "{".to_string(),
|
||||
token::CloseDelim(token::Brace) => "}".to_string(),
|
||||
token::OpenDelim(token::NoDelim) | token::CloseDelim(token::NoDelim) => " ".to_string(),
|
||||
token::OpenDelim(token::NoDelim) | token::CloseDelim(token::NoDelim) => "".to_string(),
|
||||
token::Pound => "#".to_string(),
|
||||
token::Dollar => "$".to_string(),
|
||||
token::Question => "?".to_string(),
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
PRINT-BANG INPUT (DISPLAY): A
|
||||
PRINT-BANG RE-COLLECTED (DISPLAY): A
|
||||
PRINT-BANG INPUT (DEBUG): TokenStream [
|
||||
Group {
|
||||
delimiter: None,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
PRINT-BANG INPUT (DISPLAY): FirstStruct
|
||||
PRINT-BANG INPUT (DISPLAY): FirstStruct
|
||||
PRINT-BANG INPUT (DEBUG): TokenStream [
|
||||
Group {
|
||||
delimiter: None,
|
||||
|
@ -12,7 +12,6 @@ PRINT-BANG INPUT (DEBUG): TokenStream [
|
|||
},
|
||||
]
|
||||
PRINT-BANG INPUT (DISPLAY): SecondStruct
|
||||
PRINT-BANG RE-COLLECTED (DISPLAY): SecondStruct
|
||||
PRINT-BANG INPUT (DEBUG): TokenStream [
|
||||
Group {
|
||||
delimiter: None,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue