rust/compiler
bors 4ae328bef4 Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov
Properly handle attributes on statements

We now collect tokens for the underlying node wrapped by `StmtKind`
nstead of storing tokens directly in `Stmt`.

`LazyTokenStream` now supports capturing a trailing semicolon after it
is initially constructed. This allows us to avoid refactoring statement
parsing to wrap the parsing of the semicolon in `parse_tokens`.

Attributes on item statements
(e.g. `fn foo() { #[bar] struct MyStruct; }`) are now treated as
item attributes, not statement attributes, which is consistent with how
we handle attributes on other kinds of statements. The feature-gating
code is adjusted so that proc-macro attributes are still allowed on item
statements on stable.

Two built-in macros (`#[global_allocator]` and `#[test]`) needed to be
adjusted to support being passed `Annotatable::Stmt`.
2020-11-28 07:48:56 +00:00
..
rustc
rustc_apfloat
rustc_arena
rustc_ast Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00
rustc_ast_lowering Auto merge of #79318 - cjgillot:fitem, r=lcnr 2020-11-27 13:45:22 +00:00
rustc_ast_passes Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00
rustc_ast_pretty
rustc_attr
rustc_builtin_macros Properly handle attributes on statements 2020-11-26 17:08:35 -05:00
rustc_codegen_cranelift Auto merge of #79336 - camelid:rename-feature-oibit-to-auto, r=oli-obk 2020-11-25 07:25:19 +00:00
rustc_codegen_llvm Rollup merge of #79365 - richkadel:llvm-cov-map-version-4, r=wesleywiser 2020-11-26 13:39:09 +01:00
rustc_codegen_ssa Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00
rustc_data_structures Rename optin_builtin_traits to auto_traits 2020-11-23 14:14:06 -08:00
rustc_driver Auto merge of #77671 - flip1995:lint_list_always_plugins, r=oli-obk,Manishearth 2020-11-26 18:51:45 +00:00
rustc_error_codes Rename optin_builtin_traits to auto_traits 2020-11-23 14:14:06 -08:00
rustc_errors
rustc_expand Properly handle attributes on statements 2020-11-26 17:08:35 -05:00
rustc_feature Rename optin_builtin_traits to auto_traits 2020-11-23 14:14:06 -08:00
rustc_fs_util
rustc_graphviz
rustc_hir Formatting. 2020-11-26 21:32:29 +01:00
rustc_hir_pretty Remove ForeignMod struct. 2020-11-26 21:32:27 +01:00
rustc_incremental Remove ForeignMod struct. 2020-11-26 21:32:27 +01:00
rustc_index Stabilise then 2020-11-22 13:45:14 +00:00
rustc_infer Rollup merge of #77758 - Stupremee:turbofish-help-for-const, r=varkor 2020-11-26 13:39:00 +01:00
rustc_interface Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00
rustc_lexer
rustc_lint Don't lint on redundant semicolons after item statements 2020-11-27 09:37:49 -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 Improved version check 2020-11-25 09:45:33 -08:00
rustc_macros
rustc_metadata Encode proc_macro directly. 2020-11-27 20:39:49 +01:00
rustc_middle Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00
rustc_mir Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00
rustc_mir_build Rename _match to usefulness 2020-11-27 18:43:28 +00:00
rustc_parse Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00
rustc_parse_format
rustc_passes Use visitor for its very purpose. 2020-11-26 21:32:29 +01:00
rustc_plugin_impl Store ForeignItem in a side table. 2020-11-26 21:29:27 +01:00
rustc_privacy Remove ForeignMod struct. 2020-11-26 21:32:27 +01:00
rustc_query_system
rustc_resolve Remove ForeignMod struct. 2020-11-26 21:32:27 +01:00
rustc_save_analysis Remove ForeignMod struct. 2020-11-26 21:32:27 +01:00
rustc_serialize
rustc_session TRACK '-Z polonius' flag 2020-11-24 20:08:54 -08:00
rustc_span Rollup merge of #79000 - sivadeilra:user/ardavis/lev_distance, r=wesleywiser 2020-11-26 13:39:05 +01:00
rustc_symbol_mangling Store ForeignItem in a side table. 2020-11-26 21:29:27 +01:00
rustc_target Add support for Arm64 Catalyst on ARM Macs 2020-11-26 11:31:59 +01:00
rustc_trait_selection Rollup merge of #79325 - LingMan:try_op, r=jonas-schievink 2020-11-23 15:25:47 +01:00
rustc_traits
rustc_ty_utils Fix new 'unnecessary trailing semicolon' warnings 2020-11-26 17:08:36 -05:00
rustc_typeck Auto merge of #78296 - Aaron1011:fix/stmt-tokens, r=petrochenkov 2020-11-28 07:48:56 +00:00