Skip to content

Commit 00358b1

Browse files
committed
rebase on lastest master
1 parent dba1675 commit 00358b1

File tree

2 files changed

+13
-16
lines changed

2 files changed

+13
-16
lines changed

crates/hir/src/display.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,7 @@ use hir_ty::{
1717
};
1818

1919
use crate::{
20-
Adt, AsAssocItem, AssocItemContainer, Const, ConstParam, Enum, ExternCrateDecl, Field,
21-
Function, GenericParam, HasCrate, HasVisibility, LifetimeParam, Macro, Module, SelfParam,
22-
Static, Struct, Trait, TraitAlias, TupleField, TyBuilder, Type, TypeAlias, TypeOrConstParam,
23-
TypeParam, Union, Variant,
20+
Adt, AsAssocItem, AssocItem, AssocItemContainer, Const, ConstParam, Enum, ExternCrateDecl, Field, Function, GenericParam, HasCrate, HasVisibility, LifetimeParam, Macro, Module, SelfParam, Static, Struct, Trait, TraitAlias, TupleField, TyBuilder, Type, TypeAlias, TypeOrConstParam, TypeParam, Union, Variant
2421
};
2522

2623
impl HirDisplay for Function {

crates/ide/src/hover/tests.rs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ fn main() {
411411
name: "FnOnce",
412412
kind: Trait,
413413
container_name: "function",
414-
description: "pub trait FnOnce<Args>\nwhere\n Args: Tuple,",
414+
description: "pub trait FnOnce<Args>\nwhere\n Args: Tuple, {\n pub type Output,\n pub extern \"rust-call\" fn call_once(self, args: Args) -> Self::Output,\n}",
415415
},
416416
},
417417
],
@@ -2766,7 +2766,7 @@ fn main() { let s$0t = foo(); }
27662766
focus_range: 19..22,
27672767
name: "Bar",
27682768
kind: Trait,
2769-
description: "trait Bar",
2769+
description: "trait Bar {}",
27702770
},
27712771
},
27722772
HoverGotoTypeData {
@@ -2779,7 +2779,7 @@ fn main() { let s$0t = foo(); }
27792779
focus_range: 6..9,
27802780
name: "Foo",
27812781
kind: Trait,
2782-
description: "trait Foo",
2782+
description: "trait Foo {}",
27832783
},
27842784
},
27852785
],
@@ -2816,7 +2816,7 @@ fn main() { let s$0t = foo(); }
28162816
focus_range: 22..25,
28172817
name: "Bar",
28182818
kind: Trait,
2819-
description: "trait Bar<T>",
2819+
description: "trait Bar<T> {}",
28202820
},
28212821
},
28222822
HoverGotoTypeData {
@@ -2829,7 +2829,7 @@ fn main() { let s$0t = foo(); }
28292829
focus_range: 6..9,
28302830
name: "Foo",
28312831
kind: Trait,
2832-
description: "trait Foo<T>",
2832+
description: "trait Foo<T> {}",
28332833
},
28342834
},
28352835
HoverGotoTypeData {
@@ -2920,7 +2920,7 @@ fn foo(ar$0g: &impl Foo + Bar<S>) {}
29202920
focus_range: 19..22,
29212921
name: "Bar",
29222922
kind: Trait,
2923-
description: "trait Bar<T>",
2923+
description: "trait Bar<T> {}",
29242924
},
29252925
},
29262926
HoverGotoTypeData {
@@ -2933,7 +2933,7 @@ fn foo(ar$0g: &impl Foo + Bar<S>) {}
29332933
focus_range: 6..9,
29342934
name: "Foo",
29352935
kind: Trait,
2936-
description: "trait Foo",
2936+
description: "trait Foo {}",
29372937
},
29382938
},
29392939
HoverGotoTypeData {
@@ -3220,7 +3220,7 @@ fn foo(a$0rg: &impl ImplTrait<B<dyn DynTrait<B<S>>>>) {}
32203220
focus_range: 28..36,
32213221
name: "DynTrait",
32223222
kind: Trait,
3223-
description: "trait DynTrait<T>",
3223+
description: "trait DynTrait<T> {}",
32243224
},
32253225
},
32263226
HoverGotoTypeData {
@@ -3233,7 +3233,7 @@ fn foo(a$0rg: &impl ImplTrait<B<dyn DynTrait<B<S>>>>) {}
32333233
focus_range: 6..15,
32343234
name: "ImplTrait",
32353235
kind: Trait,
3236-
description: "trait ImplTrait<T>",
3236+
description: "trait ImplTrait<T> {}",
32373237
},
32383238
},
32393239
HoverGotoTypeData {
@@ -7456,7 +7456,7 @@ impl Iterator for S {
74567456
name: "Future",
74577457
kind: Trait,
74587458
container_name: "future",
7459-
description: "pub trait Future",
7459+
description: "pub trait Future {\n pub type Output,\n pub fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>,\n}",
74607460
},
74617461
},
74627462
HoverGotoTypeData {
@@ -7470,7 +7470,7 @@ impl Iterator for S {
74707470
name: "Iterator",
74717471
kind: Trait,
74727472
container_name: "iterator",
7473-
description: "pub trait Iterator",
7473+
description: "pub trait Iterator {\n pub type Item,\n pub fn next(&mut self) -> Option<Self::Item>,\n pub fn nth(&mut self, n: usize) -> Option<Self::Item>,\n pub fn by_ref(&mut self) -> &mut Self\nwhere\n Self: Sized,,\n}",
74747474
},
74757475
},
74767476
HoverGotoTypeData {
@@ -7483,7 +7483,7 @@ impl Iterator for S {
74837483
focus_range: 49..56,
74847484
name: "Notable",
74857485
kind: Trait,
7486-
description: "trait Notable",
7486+
description: "trait Notable {}",
74877487
},
74887488
},
74897489
HoverGotoTypeData {

0 commit comments

Comments
 (0)