rust/compiler
bors 1e3d632f8f Auto merge of #88087 - jesyspa:issue-87935-box, r=jackh726
Check that a box expression's type is Sized

This resolves [issue 87935](https://github.com/rust-lang/rust/issues/87935).

This makes E0161 (move from an unsized rvalue) much less common.  I've replaced the test to use [this case](https://github.com/rust-lang/rust/blob/master/src/test/ui/object-safety/object-safety-by-value-self-use.rs), when a boxed `dyn` trait is passed by value, but that isn't an error when `unsized_locals` is enabled.  I think it may be possible to get rid of E0161 entirely by checking that case earlier, but I'm not sure if that's desirable?
2021-08-20 23:04:57 +00:00
..
rustc rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_apfloat rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_arena rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_ast Remove box syntax from rustc_ast 2021-08-18 09:25:26 +02:00
rustc_ast_lowering Introduce hir::ExprKind::Let - Take 2 2021-08-15 16:18:26 -03:00
rustc_ast_passes Auto merge of #86860 - fee1-dead:stabilize, r=LeSeulArtichaut 2021-08-18 01:00:17 +00:00
rustc_ast_pretty Introduce hir::ExprKind::Let - Take 2 2021-08-15 16:18:26 -03:00
rustc_attr rustc: Fill out remaining parts of C-unwind ABI 2021-08-03 07:06:19 -07:00
rustc_builtin_macros Remove box syntax from rustc_builtin_macros 2021-08-18 09:25:26 +02:00
rustc_codegen_cranelift remove box_syntax uses from cranelift and tools 2021-08-18 09:31:51 +02:00
rustc_codegen_llvm Include (potentially remapped) working dir in crate hash 2021-08-15 15:17:37 -05:00
rustc_codegen_ssa Update the backtrace crate in libstd 2021-08-19 07:31:49 -07:00
rustc_data_structures Remove duplicate trait bounds in rustc_data_structures::graph 2021-08-09 08:52:04 -05:00
rustc_driver Reduce verbosity of RUSTC_LOG 2021-08-09 21:39:39 -04:00
rustc_error_codes Change example and tests for E0161. 2021-08-20 15:59:42 +02:00
rustc_errors Modify structured suggestion output 2021-08-11 09:46:24 +00:00
rustc_expand Introduce hir::ExprKind::Let - Take 2 2021-08-15 16:18:26 -03:00
rustc_feature Auto merge of #86860 - fee1-dead:stabilize, r=LeSeulArtichaut 2021-08-18 01:00:17 +00:00
rustc_fs_util rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_graphviz rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_hir Introduce hir::ExprKind::Let - Take 2 2021-08-15 16:18:26 -03:00
rustc_hir_pretty Introduce hir::ExprKind::Let - Take 2 2021-08-15 16:18:26 -03:00
rustc_incremental rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_index rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_infer Auto merge of #86700 - lqd:matthews-nll-hrtb-errors, r=nikomatsakis 2021-08-18 15:54:59 +00:00
rustc_interface Replace #[plugin_registrar] with exporting __rustc_plugin_registrar 2021-08-10 14:20:48 +02:00
rustc_lexer Renamed variable str -> tail for clarity 2021-08-11 13:57:28 +02:00
rustc_lint Remove box syntax from rustc_lint 2021-08-18 09:31:51 +02:00
rustc_lint_defs Auto merge of #87324 - asquared31415:named-asm-labels, r=Amanieu 2021-08-14 17:33:38 +00:00
rustc_llvm Auto merge of #87798 - durin42:llvm-14, r=nikic 2021-08-08 04:33:22 +00:00
rustc_macros Rollup merge of #86123 - Aaron1011:query-span, r=cjgillot 2021-08-19 19:30:04 +02:00
rustc_metadata Include (potentially remapped) working dir in crate hash 2021-08-15 15:17:37 -05:00
rustc_middle Require a box expression's type to be Sized 2021-08-20 16:25:52 +02:00
rustc_mir Auto merge of #88087 - jesyspa:issue-87935-box, r=jackh726 2021-08-20 23:04:57 +00:00
rustc_mir_build Auto merge of #88039 - sexxi-goose:fix-87987, r=nikomatsakis 2021-08-20 02:19:58 +00:00
rustc_parse Remove box syntax from rustc_parse 2021-08-18 09:25:26 +02:00
rustc_parse_format rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_passes Rollup merge of #88036 - nbdd0121:const3, r=petrochenkov 2021-08-18 19:54:59 +02:00
rustc_plugin_impl Replace #[plugin_registrar] with exporting __rustc_plugin_registrar 2021-08-10 14:20:48 +02:00
rustc_privacy rustc_privacy: Replace HirIds and DefIds with LocalDefIds where possible 2021-08-19 00:01:12 +03:00
rustc_query_impl Auto merge of #87515 - crlf0710:trait_upcasting_part2, r=bjorn3 2021-08-03 16:58:56 +00:00
rustc_query_system Prevent double panic when handling incremental fingerprint mismatch 2021-08-12 15:11:39 -05:00
rustc_resolve review comment: use newtype to deduplicate logic 2021-08-18 14:05:15 +00:00
rustc_save_analysis Include (potentially remapped) working dir in crate hash 2021-08-15 15:17:37 -05:00
rustc_serialize Remove box syntax from rustc_serialize 2021-08-18 09:25:26 +02:00
rustc_session Include (potentially remapped) working dir in crate hash 2021-08-15 15:17:37 -05:00
rustc_span Rollup merge of #88050 - Aaron1011:filename-hash-stable, r=michaelwoerister 2021-08-19 19:30:07 +02:00
rustc_symbol_mangling Auto merge of #85296 - bjorn3:plugin_cleanup, r=petrochenkov 2021-08-12 04:30:41 +00:00
rustc_target Auto merge of #88023 - devnexen:fbsd_arm64, r=nagisa 2021-08-19 11:54:27 +00:00
rustc_trait_selection Require a box expression's type to be Sized 2021-08-20 16:25:52 +02:00
rustc_traits Auto merge of #86700 - lqd:matthews-nll-hrtb-errors, r=nikomatsakis 2021-08-18 15:54:59 +00:00
rustc_ty_utils rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_type_ir rfc3052: Remove authors field from Cargo manifests 2021-07-29 14:56:05 -07:00
rustc_typeck Auto merge of #88087 - jesyspa:issue-87935-box, r=jackh726 2021-08-20 23:04:57 +00:00