rust-analyzer/crates
Morgan Thomas 2a22cf8efc Complete enum variants identically to structures.
In particular:
 - unit variants now display in the menu as "Variant", complete to "Variant", and display a detail of "Variant" (was "()")
 - tuple variants now display in the menu as "Variant(…)", complete to "Variant(${1:()})$0" (was "Variant($0)"), and display a detail of "Variant(type)" (was "(type)")
 - record variants now display in the menu as "Variant {…}", complete to "Variant { x: ${1:()} }$0" (was "Variant"), and display a detail of "Variant { x: type }" (was "{x: type}")

This behavior is identical to that of struct completions. In addition, tuple variants no longer set triggers_call_info, as to my understanding it's unnecessary now that we're emitting placeholders.

Tests have been updated to match, and the render::enum_variant::tests::inserts_parens_for_tuple_enums test has been removed entirely as it's covered by other tests (render::enum_detail_includes_{record, tuple}_fields, render::enum_detail_just_name_for_unit, render::pattern::enum_qualified).
2022-03-11 18:26:01 -08:00
..
base_db fix: Properly handle proc-macro crate types for nameres 2022-03-09 14:33:39 +01:00
cfg Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00
flycheck Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00
hir fix: Show what file paths were expected for unresolved modules 2022-03-11 17:08:30 +01:00
hir_def fix: Show what file paths were expected for unresolved modules 2022-03-11 17:08:30 +01:00
hir_expand Expand into pseudo-derive attribute expansions in completions 2022-03-10 20:53:50 +01:00
hir_ty Merge #11660 2022-03-09 17:18:03 +00:00
ide Don't parse source files to generate macro completion details 2022-03-10 22:21:58 +01:00
ide_assists Expand into pseudo-derive attribute expansions in completions 2022-03-10 20:53:50 +01:00
ide_completion Complete enum variants identically to structures. 2022-03-11 18:26:01 -08:00
ide_db Expand into pseudo-derive attribute expansions in completions 2022-03-10 20:53:50 +01:00
ide_diagnostics fix: Show what file paths were expected for unresolved modules 2022-03-11 17:08:30 +01:00
ide_ssr Disable one of the failing SSR test cases 2022-03-09 02:08:44 +01:00
limit Use compare_exchange_weak in limit::Limit::check 2022-01-28 18:19:35 +03:00
mbe Do not consider _ to be an expression for macro_rules! 2022-03-02 01:51:25 +00:00
parser Add support for new where clause location in associated types. 2022-03-10 18:21:29 +01:00
paths Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00
proc_macro_api Set current working directory for procedural macros 2022-01-27 16:18:12 +03:00
proc_macro_srv fix: Fix proc-macro server not using the supplied span in Ident::new 2022-01-31 17:02:57 +01:00
proc_macro_test Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00
profile Generate AnyHasDocComments node 2022-01-07 12:38:18 +01:00
project_model Update project_model test outputs 2022-03-09 22:34:42 +01:00
rust-analyzer fix: Show what file paths were expected for unresolved modules 2022-03-11 17:08:30 +01:00
sourcegen Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00
stdx Generate AnyHasDocComments node 2022-01-07 12:38:18 +01:00
syntax Don't parse source files to generate macro completion details 2022-03-10 22:21:58 +01:00
test_utils fix: Do not complete Drop::drop, complete std::mem::drop instead 2021-12-22 02:25:38 +01:00
text_edit redirct: use iterators and knowledge about preordered arrays for more efficient merging 2022-02-28 05:56:51 +01:00
toolchain Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00
tt Track synthetic tokens, to be able to remove them again later 2022-02-08 18:13:18 +01:00
vfs Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00
vfs-notify Bump MSRV (1.57) 2021-12-16 01:56:12 +05:00