]> git.lizzy.rs Git - rust.git/commitdiff
Rollup merge of #52539 - alexcrichton:two-attrs, r=petrochenkov
authorkennytm <kennytm@gmail.com>
Fri, 20 Jul 2018 18:59:09 +0000 (02:59 +0800)
committerkennytm <kennytm@gmail.com>
Fri, 20 Jul 2018 20:08:10 +0000 (04:08 +0800)
rustc: Fix two custom attributes with custom derive

This commit fixes an issue where multiple custom attributes could not be fed
into a custom derive in some situations with the `use_extern_macros` feature
enabled. The problem was that the macro expander didn't consider that it was
making progress when we were deducing that attributes should be lumped in with
custom derive invocations.

The fix applied here was to track in the expander if our attribute is changing
(getting stashed away elsewhere and replaced with a new invocation). If it is
swapped then it's considered progress, otherwise behavior should remain the
same.

Closes #52525


Trivial merge