about summary refs log tree commit diff
path: root/src/test/ui/macros/auxiliary
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-254/+0
2022-11-03Move some tests from `src/test/ui` to more reasonable placesDeadbeef-0/+15
2022-08-07Add UI test for #100199Luqman Aden-0/+18
2022-03-09Permit `#[deprecated]` in stdlibJacob Pratt-1/+1
2022-03-04Change `rustc_deprecated` to use `note`Jacob Pratt-1/+1
This keeps `reason` around for the time being. This is necessary to avoid breakage during the bootstrap process. This change, as a whole, brings `#[rustc_deprecated]` more in line with `#[deprecated]`.
2021-11-14Move some tests to more reasonable directoriesCaio-0/+35
2021-11-06Move some tests to more reasonable directoriesCaio-0/+6
2021-10-02resolve: Cache module loading for all foreign modulesVadim Petrochenkov-0/+13
It was previously cached for modules loaded from `fn get_module`, but not for modules loaded from `fn build_reduced_graph_for_external_crate_res`. This also makes all foreign modules use their real parent, span and expansion instead of possibly a parent/span/expansion of their reexport. An ICE happening on attempt to decode expansions for foreign enums and traits is avoided. Also local enums and traits are now added to the module map.
2021-09-15Move some tests to more reasonable directoriesCaio-0/+6
2021-06-24Don't lint :pat when re-parsing a macro from another crate.Mara Bos-0/+6
2021-05-29Use correct edition when parsing `:pat` matchersAaron Hill-0/+11
As described in issue #85708, we currently do not properly decode `SyntaxContext::root()` and `ExpnId::root()` from foreign crates. As a result, when we decode a span from a foreign crate with `SyntaxContext::root()`, we end up up considering it to have the edition of the *current* crate, instead of the foreign crate where it was originally created. A full fix for this issue will be a fairly significant undertaking. Fortunately, it's possible to implement a partial fix, which gives us the correct edition-dependent behavior for `:pat` matchers when the macro is loaded from another crate. Since we have the edition of the macro's defining crate available, we can 'recover' from seeing a `SyntaxContext::root()` and use the edition of the macro's defining crate. Any solution to issue #85708 must reproduce the behavior of this targeted fix - properly preserving a foreign `SyntaxContext::root()` means (among other things) preserving its edition, which by definition is the edition of the foreign crate itself. Therefore, this fix moves us closer to the correct overall solution, and does not expose any new incorrect behavior to macros.
2021-05-12Update stderrAaron Hill-19/+0
The spans generated by `quote!` are (intentionally) no longer all the same, so I removed that check entirely.
2021-01-16Move some tests to more reasonable directories - 2Caio-0/+1
Address comments Update limits
2020-10-24Compute proper module parent during resolutionAaron Hill-0/+12
Fixes #75982 The direct parent of a module may not be a module (e.g. `const _: () = { #[path = "foo.rs"] mod foo; };`). To find the parent of a module for purposes of resolution, we need to walk up the tree until we hit a module or a crate root.
2020-05-03Stabilize fn-like proc macros in expression, pattern and statement positionsVadim Petrochenkov-1/+1
2019-12-21Require issue = "none" over issue = "0" in unstable attributesRoss MacArthur-2/+2
2019-08-27proc_macro: Update `Span::def_site` to use the proc macro definition locationVadim Petrochenkov-5/+15
Which is no longer dummy and is available from metadata now.
2019-07-27tests: Move run-pass tests without naming conflicts to uiVadim Petrochenkov-0/+44
2019-07-25Implement slow-path for FirstSets::firstJulien Cretin-0/+36
When 2 or more sequences share the same span, we can't use the precomputed map for their first set. So we compute it recursively. Fixes #62831.
2019-07-11pretty-print: Do not lose the `$crate` printing flag in `print_tt`Vadim Petrochenkov-0/+10
2019-07-07Support deprecation checking for macrosVadim Petrochenkov-0/+13
2018-12-25Remove licensesMark Rousskov-40/+0
2018-09-08resolve: Relax shadowing restriction on macro-expanded macrosVadim Petrochenkov-0/+5
... for both legacy and modern macros. Fix previously introduced regressions, add tests.
2018-08-14Merged migrated compile-fail tests and ui tests. Fixes #46841.David Wood-0/+72