File tree 2 files changed +12
-0
lines changed
main/kotlin/org/rust/ide/presentation
test/kotlin/org/rust/ide/lineMarkers
2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -74,6 +74,9 @@ private fun presentableName(psi: RsElement): String? {
74
74
val trait = psi.traitRef?.text
75
75
buildString {
76
76
if (trait != null ) {
77
+ if (psi.isNegativeImpl) {
78
+ append(" !" )
79
+ }
77
80
append(" $trait for " )
78
81
}
79
82
append(type)
Original file line number Diff line number Diff line change @@ -50,14 +50,23 @@ class RsImplsLineMarkerProviderTest : RsLineMarkerProviderTestBase() {
50
50
impl Foo for Bar {}
51
51
""" )
52
52
53
+ fun `test negative impls` () = doPopupTest("""
54
+ trait Foo {}
55
+ struct Bar/*caret*/;
56
+ impl !Foo for Bar {}
57
+ """ , " !Foo for Bar" )
58
+
53
59
fun `test impls sorting` () = doPopupTest("""
54
60
trait Bar {}
55
61
trait Foo {}
62
+ trait Baz {}
56
63
struct FooBar/*caret*/;
57
64
58
65
impl Foo for FooBar {}
59
66
impl Bar for FooBar {}
67
+ impl !Baz for FooBar {}
60
68
""" ,
69
+ " !Baz for FooBar" ,
61
70
" Bar for FooBar" ,
62
71
" Foo for FooBar"
63
72
)
You can’t perform that action at this time.
0 commit comments