aboutsummaryrefslogtreecommitdiff
path: root/crates/completion/src/completions/unqualified_path.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/completion/src/completions/unqualified_path.rs')
-rw-r--r--crates/completion/src/completions/unqualified_path.rs74
1 files changed, 37 insertions, 37 deletions
diff --git a/crates/completion/src/completions/unqualified_path.rs b/crates/completion/src/completions/unqualified_path.rs
index 5a7a6e83d..54d5c989b 100644
--- a/crates/completion/src/completions/unqualified_path.rs
+++ b/crates/completion/src/completions/unqualified_path.rs
@@ -268,9 +268,9 @@ fn quux(x: i32) {
268} 268}
269"#, 269"#,
270 expect![[r#" 270 expect![[r#"
271 fn quux(…) fn quux(x: i32)
272 bn x i32
273 bn y i32 271 bn y i32
272 bn x i32
273 fn quux(…) fn quux(x: i32)
274 "#]], 274 "#]],
275 ); 275 );
276 } 276 }
@@ -290,8 +290,8 @@ fn quux() {
290} 290}
291"#, 291"#,
292 expect![[r#" 292 expect![[r#"
293 bn a
294 bn b i32 293 bn b i32
294 bn a
295 fn quux() fn quux() 295 fn quux() fn quux()
296 "#]], 296 "#]],
297 ); 297 );
@@ -306,8 +306,8 @@ fn quux() {
306} 306}
307"#, 307"#,
308 expect![[r#" 308 expect![[r#"
309 fn quux() fn quux()
310 bn x 309 bn x
310 fn quux() fn quux()
311 "#]], 311 "#]],
312 ); 312 );
313 } 313 }
@@ -348,9 +348,9 @@ fn main() {
348 check( 348 check(
349 r#"struct S<T> { x: <|>}"#, 349 r#"struct S<T> { x: <|>}"#,
350 expect![[r#" 350 expect![[r#"
351 st S<…>
352 tp Self 351 tp Self
353 tp T 352 tp T
353 st S<…>
354 "#]], 354 "#]],
355 ); 355 );
356 } 356 }
@@ -375,9 +375,9 @@ enum E {}
375fn quux() { <|> } 375fn quux() { <|> }
376"#, 376"#,
377 expect![[r#" 377 expect![[r#"
378 en E
379 st S 378 st S
380 fn quux() fn quux() 379 fn quux() fn quux()
380 en E
381 "#]], 381 "#]],
382 ); 382 );
383 } 383 }
@@ -429,8 +429,8 @@ mod m {
429} 429}
430"#, 430"#,
431 expect![[r#" 431 expect![[r#"
432 st Bar
433 fn quux() fn quux() 432 fn quux() fn quux()
433 st Bar
434 "#]], 434 "#]],
435 ); 435 );
436 } 436 }
@@ -475,8 +475,8 @@ fn foo() {
475 check( 475 check(
476 r#"impl S { fn foo(&self) { <|> } }"#, 476 r#"impl S { fn foo(&self) { <|> } }"#,
477 expect![[r#" 477 expect![[r#"
478 tp Self
479 bn self &{unknown} 478 bn self &{unknown}
479 tp Self
480 "#]], 480 "#]],
481 ); 481 );
482 } 482 }
@@ -495,9 +495,9 @@ use prelude::*;
495mod prelude { struct Option; } 495mod prelude { struct Option; }
496"#, 496"#,
497 expect![[r#" 497 expect![[r#"
498 st Option
499 fn foo() fn foo() 498 fn foo() fn foo()
500 md std 499 md std
500 st Option
501 "#]], 501 "#]],
502 ); 502 );
503 } 503 }
@@ -522,10 +522,10 @@ use prelude::*;
522mod prelude { struct String; } 522mod prelude { struct String; }
523"#, 523"#,
524 expect![[r#" 524 expect![[r#"
525 st String
526 md core
527 fn foo() fn foo() 525 fn foo() fn foo()
528 md std 526 md std
527 md core
528 st String
529 "#]], 529 "#]],
530 ); 530 );
531 } 531 }
@@ -551,13 +551,13 @@ mod m2 {
551fn main() { let v = <|> } 551fn main() { let v = <|> }
552"#, 552"#,
553 expect![[r##" 553 expect![[r##"
554 ma bar!(…) macro_rules! bar 554 md m1
555 ma baz!(…) #[macro_export] 555 ma baz!(…) #[macro_export]
556 macro_rules! baz 556 macro_rules! baz
557 ma foo!(…) macro_rules! foo
558 md m1
559 md m2
560 fn main() fn main() 557 fn main() fn main()
558 md m2
559 ma bar!(…) macro_rules! bar
560 ma foo!(…) macro_rules! foo
561 "##]], 561 "##]],
562 ); 562 );
563 } 563 }
@@ -570,8 +570,8 @@ macro_rules! foo { () => {} }
570fn foo() { <|> } 570fn foo() { <|> }
571"#, 571"#,
572 expect![[r#" 572 expect![[r#"
573 ma foo!(…) macro_rules! foo
574 fn foo() fn foo() 573 fn foo() fn foo()
574 ma foo!(…) macro_rules! foo
575 "#]], 575 "#]],
576 ); 576 );
577 } 577 }
@@ -584,8 +584,8 @@ macro_rules! foo { () => {} }
584fn main() { let x: <|> } 584fn main() { let x: <|> }
585"#, 585"#,
586 expect![[r#" 586 expect![[r#"
587 ma foo!(…) macro_rules! foo
588 fn main() fn main() 587 fn main() fn main()
588 ma foo!(…) macro_rules! foo
589 "#]], 589 "#]],
590 ); 590 );
591 } 591 }
@@ -598,8 +598,8 @@ macro_rules! foo { () => {} }
598fn main() { <|> } 598fn main() { <|> }
599"#, 599"#,
600 expect![[r#" 600 expect![[r#"
601 ma foo!(…) macro_rules! foo
602 fn main() fn main() 601 fn main() fn main()
602 ma foo!(…) macro_rules! foo
603 "#]], 603 "#]],
604 ); 604 );
605 } 605 }
@@ -631,10 +631,10 @@ fn quux(x: i32) {
631} 631}
632"#, 632"#,
633 expect![[r#" 633 expect![[r#"
634 ma m!(…) macro_rules! m
635 fn quux(…) fn quux(x: i32)
636 bn x i32
637 bn y i32 634 bn y i32
635 bn x i32
636 fn quux(…) fn quux(x: i32)
637 ma m!(…) macro_rules! m
638 "#]], 638 "#]],
639 ); 639 );
640 } 640 }
@@ -650,10 +650,10 @@ fn quux(x: i32) {
650} 650}
651", 651",
652 expect![[r#" 652 expect![[r#"
653 ma m!(…) macro_rules! m
654 fn quux(…) fn quux(x: i32)
655 bn x i32
656 bn y i32 653 bn y i32
654 bn x i32
655 fn quux(…) fn quux(x: i32)
656 ma m!(…) macro_rules! m
657 "#]], 657 "#]],
658 ); 658 );
659 } 659 }
@@ -669,10 +669,10 @@ fn quux(x: i32) {
669} 669}
670"#, 670"#,
671 expect![[r#" 671 expect![[r#"
672 ma m!(…) macro_rules! m
673 fn quux(…) fn quux(x: i32)
674 bn x i32
675 bn y i32 672 bn y i32
673 bn x i32
674 fn quux(…) fn quux(x: i32)
675 ma m!(…) macro_rules! m
676 "#]], 676 "#]],
677 ); 677 );
678 } 678 }
@@ -686,8 +686,8 @@ use spam::Quux;
686fn main() { <|> } 686fn main() { <|> }
687"#, 687"#,
688 expect![[r#" 688 expect![[r#"
689 ?? Quux
690 fn main() fn main() 689 fn main() fn main()
690 ?? Quux
691 "#]], 691 "#]],
692 ); 692 );
693 } 693 }
@@ -703,10 +703,10 @@ fn main() {
703} 703}
704"#, 704"#,
705 expect![[r#" 705 expect![[r#"
706 en Foo
707 ev Foo::Bar () 706 ev Foo::Bar ()
708 ev Foo::Baz () 707 ev Foo::Baz ()
709 ev Foo::Quux () 708 ev Foo::Quux ()
709 en Foo
710 "#]], 710 "#]],
711 ) 711 )
712 } 712 }
@@ -723,10 +723,10 @@ fn main() {
723} 723}
724"#, 724"#,
725 expect![[r#" 725 expect![[r#"
726 en Foo
727 ev Foo::Bar () 726 ev Foo::Bar ()
728 ev Foo::Baz () 727 ev Foo::Baz ()
729 ev Foo::Quux () 728 ev Foo::Quux ()
729 en Foo
730 "#]], 730 "#]],
731 ) 731 )
732 } 732 }
@@ -739,10 +739,10 @@ enum Foo { Bar, Baz, Quux }
739fn main() { let foo: Foo = Q<|> } 739fn main() { let foo: Foo = Q<|> }
740"#, 740"#,
741 expect![[r#" 741 expect![[r#"
742 en Foo
743 ev Foo::Bar () 742 ev Foo::Bar ()
744 ev Foo::Baz () 743 ev Foo::Baz ()
745 ev Foo::Quux () 744 ev Foo::Quux ()
745 en Foo
746 fn main() fn main() 746 fn main() fn main()
747 "#]], 747 "#]],
748 ) 748 )
@@ -756,9 +756,9 @@ mod m { pub enum E { V } }
756fn f() -> m::E { V<|> } 756fn f() -> m::E { V<|> }
757"#, 757"#,
758 expect![[r#" 758 expect![[r#"
759 fn f() fn f() -> m::E
760 md m
761 ev m::E::V () 759 ev m::E::V ()
760 md m
761 fn f() fn f() -> m::E
762 "#]], 762 "#]],
763 ) 763 )
764 } 764 }
@@ -785,9 +785,9 @@ struct MyStruct {}
785impl My<|> 785impl My<|>
786"#, 786"#,
787 expect![[r#" 787 expect![[r#"
788 st MyStruct
789 tt MyTrait
790 tp Self 788 tp Self
789 tt MyTrait
790 st MyStruct
791 "#]], 791 "#]],
792 ) 792 )
793 } 793 }
@@ -919,13 +919,13 @@ fn main() {
919} 919}
920"#, 920"#,
921 expect![[r#" 921 expect![[r#"
922 st FirstStruct 922 fn main() fn main()
923 st SecondStruct 923 st SecondStruct
924 st FirstStruct
924 md dep 925 md dep
925 st dep::some_module::ThirdStruct 926 st dep::some_module::ThirdStruct
926 st dep::some_module::AfterThirdStruct 927 st dep::some_module::AfterThirdStruct
927 st dep::some_module::ThiiiiiirdStruct 928 st dep::some_module::ThiiiiiirdStruct
928 fn main() fn main()
929 "#]], 929 "#]],
930 ); 930 );
931 } 931 }