1
Fork 0

Remove TokenStream::flattened and InvisibleOrigin::FlattenToken.

They are no longer needed.

This does slightly worsen the error message for a single test, but that
test contains code that is so badly broken that I'm not worried about
it.
This commit is contained in:
Nicholas Nethercote 2024-07-04 10:16:51 +10:00
parent 4d8f7577b5
commit 4c0cbaeb9e
8 changed files with 12 additions and 70 deletions

View file

@ -320,7 +320,7 @@ impl<'sess> AttributeParser<'sess> {
ast::AttrArgs::Delimited(args) => AttrArgs::Delimited(DelimArgs {
dspan: args.dspan,
delim: args.delim,
tokens: args.tokens.flattened(),
tokens: args.tokens.clone(),
}),
// This is an inert key-value attribute - it will never be visible to macros
// after it gets lowered to HIR. Therefore, we can extract literals to handle