rust/compiler
bors 6331023708 Auto merge of #79294 - petrochenkov:determ, r=varkor
resolve: Do not put macros into `module.unexpanded_invocations` unless necessary

Macro invocations in modules <sup>(*)</sup> need to be tracked because they can produce named items when expanded.
We cannot give definite answer to queries like "does this module declare name `n`?" until all macro calls in that module are expanded.

Previously we marked too many macros as potentially producing named items.
E.g. in this example
```rust
mod m {
    const C: u32 = line!();
}
```
`line!()` cannot emit any items into module `m`, but it was still marked.
This PR fixes that and marks macro calls as "unexpanded in module" only if they can actually emit named items into that module.

Diagnostics in UI test outputs have different order now because this change affects macro expansion order.

<sup>*</sup> Any containers for named items are called modules in resolve (that includes blocks, traits and enums in addition to `mod` items).
2020-11-24 09:17:33 +00:00
..
rustc just max_level_info 2020-09-11 09:37:51 -07:00
rustc_apfloat Backport another LLVM commit to rustc_apfloat 2020-10-04 02:02:25 +02:00
rustc_arena Use specialization to avoid copying 2020-11-20 21:02:09 +01:00
rustc_ast Rollup merge of #79016 - fanzier:underscore-expressions, r=petrochenkov 2020-11-15 13:39:48 +01:00
rustc_ast_lowering Rollup merge of #79016 - fanzier:underscore-expressions, r=petrochenkov 2020-11-15 13:39:48 +01:00
rustc_ast_passes Use span_suggestion_verbose instead of span_suggestion for fn with qualifiers inside an extern "C" block 2020-11-17 07:57:54 -06:00
rustc_ast_pretty Rollup merge of #79016 - fanzier:underscore-expressions, r=petrochenkov 2020-11-15 13:39:48 +01:00
rustc_attr Never inline naked functions 2020-11-20 00:00:00 +00:00
rustc_builtin_macros Reduce boilerplate with the ? operator 2020-11-23 00:58:53 +01:00
rustc_codegen_cranelift Drop support for cloudabi targets 2020-11-22 17:11:41 -05:00
rustc_codegen_llvm Use Option::map instead of open coding it 2020-11-23 04:58:21 +01:00
rustc_codegen_ssa Use Option::and_then instead of open-coding it 2020-11-22 23:44:05 +01:00
rustc_data_structures Auto merge of #78588 - HeroicKatora:sccc, r=nikomatsakis 2020-11-21 01:30:26 +00:00
rustc_driver Direct RUSTC_LOG (tracing/log) output to stderr instead of stdout. 2020-11-20 19:34:44 +02:00
rustc_error_codes Update E0744 about control flow in const contexts to reflect the current status of const fn. 2020-11-16 09:30:29 -06:00
rustc_errors Rollup merge of #74293 - GuillaumeGomez:rustdoc-test-compiler-output-color, r=jyn514 2020-11-17 16:13:46 +01:00
rustc_expand Auto merge of #78088 - fusion-engineering-forks:panic-fmt-lint, r=estebank 2020-11-20 03:40:20 +00:00
rustc_feature Auto merge of #78801 - sexxi-goose:min_capture, r=nikomatsakis 2020-11-17 03:56:03 +00:00
rustc_fs_util Remove unused code from remaining compiler crates 2020-10-14 04:14:32 +02:00
rustc_graphviz Rust coverage before splitting instrument_coverage.rs 2020-11-05 18:24:12 -08:00
rustc_hir resolve: Introduce a separate NonMacroAttrKind for legacy derive helpers 2020-11-19 19:25:20 +03:00
rustc_hir_pretty Fix even more clippy warnings 2020-10-30 10:13:39 -04:00
rustc_incremental Allow making RUSTC_BOOTSTRAP conditional on the crate name 2020-11-07 13:45:11 -05:00
rustc_index Stabilise then 2020-11-22 13:45:14 +00:00
rustc_infer Thread Constness through selection 2020-11-22 02:13:53 +01:00
rustc_interface Move rustc_ty -> rustc_ty_utils 2020-11-19 21:57:29 +01:00
rustc_lexer Add back missing comments 2020-10-30 10:13:41 -04:00
rustc_lint More consistently use spaces after commas in lists in docs 2020-11-21 14:43:34 -05:00
rustc_lint_defs More consistently use spaces after commas in lists in docs 2020-11-21 14:43:34 -05:00
rustc_llvm fully exploited the dropped support of LLVM 8 2020-11-12 14:39:47 +01:00
rustc_macros Auto merge of #78779 - LeSeulArtichaut:ty-visitor-return, r=oli-obk 2020-11-17 12:24:34 +00:00
rustc_metadata Stabilise then 2020-11-22 13:45:14 +00:00
rustc_middle Rollup merge of #79337 - LingMan:map, r=jyn514 2020-11-23 15:25:53 +01:00
rustc_mir Rollup merge of #79287 - jonas-schievink:const-trait-impl, r=oli-obk 2020-11-23 15:25:44 +01:00
rustc_mir_build Auto merge of #79243 - Nadrieril:consolidate-tests, r=varkor 2020-11-22 18:29:38 +00:00
rustc_parse Rollup merge of #79299 - varkor:stabilise-then, r=m-ou-se 2020-11-22 23:01:08 +01:00
rustc_parse_format /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_passes Auto merge of #78801 - sexxi-goose:min_capture, r=nikomatsakis 2020-11-17 03:56:03 +00:00
rustc_plugin_impl /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_privacy Fix typo in comment 2020-11-22 20:32:36 -05:00
rustc_query_system Fix typos 2020-11-21 09:06:45 +01:00
rustc_resolve Auto merge of #79294 - petrochenkov:determ, r=varkor 2020-11-24 09:17:33 +00:00
rustc_save_analysis Rollup merge of #78352 - JohnTitor:issue-75229, r=Dylan-DPC 2020-11-15 03:02:34 +01:00
rustc_serialize Replace absolute paths with relative ones 2020-10-13 14:16:45 +02:00
rustc_session Rollup merge of #79005 - petrochenkov:noinjected, r=davidtwco 2020-11-15 13:39:46 +01:00
rustc_span Auto merge of #78801 - sexxi-goose:min_capture, r=nikomatsakis 2020-11-17 03:56:03 +00:00
rustc_symbol_mangling compiler: fold by value 2020-11-16 22:34:57 +01:00
rustc_target Drop support for cloudabi targets 2020-11-22 17:11:41 -05:00
rustc_trait_selection Rollup merge of #79325 - LingMan:try_op, r=jonas-schievink 2020-11-23 15:25:47 +01:00
rustc_traits Auto merge of #78779 - LeSeulArtichaut:ty-visitor-return, r=oli-obk 2020-11-17 12:24:34 +00:00
rustc_ty_utils Move rustc_ty -> rustc_ty_utils 2020-11-19 21:57:29 +01:00
rustc_typeck Rollup merge of #79337 - LingMan:map, r=jyn514 2020-11-23 15:25:53 +01:00