You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
macro_rules! example {(good) => {
macro_rules! good {() => {A};}};(bad) => {
macro_rules! bad {() => {A<'a>
};}};(alsobad) => {
macro_rules! bad {() => {A<B>
};}};}
Running multiple rounds of fmt in this causes both versions of bad's body to be indented indefinitely, but not good's.
Might be related to #4609, #5044 and other issues involving infinite indentation, but none of them mentioned generics.
The text was updated successfully, but these errors were encountered:
maxcabrajac
changed the title
Defining lifetimes in a macro inside macro causes infinite indentation
Defining generics in a macro inside macro causes infinite indentation
Aug 29, 2024
but also with ref, pub, &, @, #, =, | and various other punctuation characters in place of the mut. Essentially, if the body is a valid expression, no bug occurs, otherwise it will.
(Looks like almost this has been noticed before: #4609 (comment))
Running multiple rounds of fmt in this causes both versions of
bad
's body to be indented indefinitely, but notgood
's.Might be related to #4609, #5044 and other issues involving infinite indentation, but none of them mentioned generics.
The text was updated successfully, but these errors were encountered: