I experimented with this as an alternative to #191. There are a few diagnostics that this still makes worse, but I think this one is an improvement often enough that I think it's worth trying.
Here is what it does to the expanded code from the ui test:
Since we've inserted 'async_trait + at the beginning of the bounds list, instead of + 'async_trait at the end, when rustc goes to add more bounds they'll appear correctly after the last user-written bound in the source code.
I experimented with this as an alternative to #191. There are a few diagnostics that this still makes worse, but I think this one is an improvement often enough that I think it's worth trying.
Here is what it does to the expanded code from the ui test:
Since we've inserted
'async_trait +
at the beginning of the bounds list, instead of+ 'async_trait
at the end, when rustc goes to add more bounds they'll appear correctly after the last user-written bound in the source code.