aboutsummaryrefslogtreecommitdiff
path: root/crates/completion/src/render.rs
diff options
context:
space:
mode:
authorKevaundray Wedderburn <[email protected]>2021-01-06 20:15:48 +0000
committerKevaundray Wedderburn <[email protected]>2021-01-07 12:09:23 +0000
commit72b9a4fbd3c12f3250b9157a1d44230e04ec8b22 (patch)
treec138363e3592c690d841aeedb9ac97d6b2ff4396 /crates/completion/src/render.rs
parent171c3c08fe245938fb25321394233de5fe2abc7c (diff)
Change <|> to $0 - Rebase
Diffstat (limited to 'crates/completion/src/render.rs')
-rw-r--r--crates/completion/src/render.rs46
1 files changed, 23 insertions, 23 deletions
diff --git a/crates/completion/src/render.rs b/crates/completion/src/render.rs
index 7554c1565..e93c59f71 100644
--- a/crates/completion/src/render.rs
+++ b/crates/completion/src/render.rs
@@ -358,7 +358,7 @@ mod tests {
358 r#" 358 r#"
359enum Foo { Foo { x: i32, y: i32 } } 359enum Foo { Foo { x: i32, y: i32 } }
360 360
361fn main() { Foo::Fo<|> } 361fn main() { Foo::Fo$0 }
362"#, 362"#,
363 expect![[r#" 363 expect![[r#"
364 [ 364 [
@@ -381,7 +381,7 @@ fn main() { Foo::Fo<|> }
381 r#" 381 r#"
382enum Foo { Foo (i32, i32) } 382enum Foo { Foo (i32, i32) }
383 383
384fn main() { Foo::Fo<|> } 384fn main() { Foo::Fo$0 }
385"#, 385"#,
386 expect![[r#" 386 expect![[r#"
387 [ 387 [
@@ -406,7 +406,7 @@ fn main() { Foo::Fo<|> }
406 r#" 406 r#"
407enum Foo { Foo } 407enum Foo { Foo }
408 408
409fn main() { Foo::Fo<|> } 409fn main() { Foo::Fo$0 }
410"#, 410"#,
411 expect![[r#" 411 expect![[r#"
412 [ 412 [
@@ -430,7 +430,7 @@ fn main() { Foo::Fo<|> }
430mod m { 430mod m {
431 pub enum Spam { Foo, Bar(i32) } 431 pub enum Spam { Foo, Bar(i32) }
432} 432}
433fn main() { let _: m::Spam = S<|> } 433fn main() { let _: m::Spam = S$0 }
434"#, 434"#,
435 expect![[r#" 435 expect![[r#"
436 [ 436 [
@@ -483,7 +483,7 @@ fn something_deprecated() {}
483#[deprecated(since = "1.0.0")] 483#[deprecated(since = "1.0.0")]
484fn something_else_deprecated() {} 484fn something_else_deprecated() {}
485 485
486fn main() { som<|> } 486fn main() { som$0 }
487"#, 487"#,
488 expect![[r#" 488 expect![[r#"
489 [ 489 [
@@ -523,7 +523,7 @@ fn main() { som<|> }
523 check( 523 check(
524 r#" 524 r#"
525struct A { #[deprecated] the_field: u32 } 525struct A { #[deprecated] the_field: u32 }
526fn foo() { A { the<|> } } 526fn foo() { A { the$0 } }
527"#, 527"#,
528 expect![[r#" 528 expect![[r#"
529 [ 529 [
@@ -551,7 +551,7 @@ struct S {
551} 551}
552impl S { 552impl S {
553 /// Method docs 553 /// Method docs
554 fn bar(self) { self.<|> } 554 fn bar(self) { self.$0 }
555}"#, 555}"#,
556 expect![[r#" 556 expect![[r#"
557 [ 557 [
@@ -584,7 +584,7 @@ impl S {
584 584
585 check( 585 check(
586 r#" 586 r#"
587use self::my<|>; 587use self::my$0;
588 588
589/// mod docs 589/// mod docs
590mod my { } 590mod my { }
@@ -643,7 +643,7 @@ impl S {
643 #[inline] 643 #[inline]
644 fn the_method(&self) { } 644 fn the_method(&self) { }
645} 645}
646fn foo(s: S) { s.<|> } 646fn foo(s: S) { s.$0 }
647"#, 647"#,
648 expect![[r#" 648 expect![[r#"
649 [ 649 [
@@ -671,7 +671,7 @@ fn foo(foo: u8, bar: u8) {}
671struct ManualVtable { f: fn(u8, u8) } 671struct ManualVtable { f: fn(u8, u8) }
672 672
673fn main() -> ManualVtable { 673fn main() -> ManualVtable {
674 ManualVtable { f: f<|> } 674 ManualVtable { f: f$0 }
675} 675}
676"#, 676"#,
677 r#" 677 r#"
@@ -692,7 +692,7 @@ fn main() -> ManualVtable {
692 "foo", 692 "foo",
693 r#" 693 r#"
694mod m { pub fn foo() {} } 694mod m { pub fn foo() {} }
695use crate::m::f<|>; 695use crate::m::f$0;
696"#, 696"#,
697 r#" 697 r#"
698mod m { pub fn foo() {} } 698mod m { pub fn foo() {} }
@@ -707,7 +707,7 @@ use crate::m::foo;
707 "foo", 707 "foo",
708 r#" 708 r#"
709fn foo(x: i32) {} 709fn foo(x: i32) {}
710fn main() { f<|>(); } 710fn main() { f$0(); }
711"#, 711"#,
712 r#" 712 r#"
713fn foo(x: i32) {} 713fn foo(x: i32) {}
@@ -719,7 +719,7 @@ fn main() { foo(); }
719 r#" 719 r#"
720struct Foo; 720struct Foo;
721impl Foo { fn foo(&self){} } 721impl Foo { fn foo(&self){} }
722fn f(foo: &Foo) { foo.f<|>(); } 722fn f(foo: &Foo) { foo.f$0(); }
723"#, 723"#,
724 r#" 724 r#"
725struct Foo; 725struct Foo;
@@ -736,7 +736,7 @@ fn f(foo: &Foo) { foo.foo(); }
736 "Vec", 736 "Vec",
737 r#" 737 r#"
738struct Vec<T> {} 738struct Vec<T> {}
739fn foo(xs: Ve<|>) 739fn foo(xs: Ve$0)
740"#, 740"#,
741 r#" 741 r#"
742struct Vec<T> {} 742struct Vec<T> {}
@@ -747,7 +747,7 @@ fn foo(xs: Vec<$0>)
747 "Vec", 747 "Vec",
748 r#" 748 r#"
749type Vec<T> = (T,); 749type Vec<T> = (T,);
750fn foo(xs: Ve<|>) 750fn foo(xs: Ve$0)
751"#, 751"#,
752 r#" 752 r#"
753type Vec<T> = (T,); 753type Vec<T> = (T,);
@@ -758,7 +758,7 @@ fn foo(xs: Vec<$0>)
758 "Vec", 758 "Vec",
759 r#" 759 r#"
760struct Vec<T = i128> {} 760struct Vec<T = i128> {}
761fn foo(xs: Ve<|>) 761fn foo(xs: Ve$0)
762"#, 762"#,
763 r#" 763 r#"
764struct Vec<T = i128> {} 764struct Vec<T = i128> {}
@@ -769,7 +769,7 @@ fn foo(xs: Vec)
769 "Vec", 769 "Vec",
770 r#" 770 r#"
771struct Vec<T> {} 771struct Vec<T> {}
772fn foo(xs: Ve<|><i128>) 772fn foo(xs: Ve$0<i128>)
773"#, 773"#,
774 r#" 774 r#"
775struct Vec<T> {} 775struct Vec<T> {}
@@ -785,7 +785,7 @@ fn foo(xs: Vec<i128>)
785 r#" 785 r#"
786struct S { foo: i64, bar: u32, baz: u32 } 786struct S { foo: i64, bar: u32, baz: u32 }
787fn test(bar: u32) { } 787fn test(bar: u32) { }
788fn foo(s: S) { test(s.<|>) } 788fn foo(s: S) { test(s.$0) }
789"#, 789"#,
790 expect![[r#" 790 expect![[r#"
791 fd bar [type+name] 791 fd bar [type+name]
@@ -802,7 +802,7 @@ fn foo(s: S) { test(s.<|>) }
802 r#" 802 r#"
803struct A { foo: i64, bar: u32, baz: u32 } 803struct A { foo: i64, bar: u32, baz: u32 }
804struct B { x: (), y: f32, bar: u32 } 804struct B { x: (), y: f32, bar: u32 }
805fn foo(a: A) { B { bar: a.<|> }; } 805fn foo(a: A) { B { bar: a.$0 }; }
806"#, 806"#,
807 expect![[r#" 807 expect![[r#"
808 fd bar [type+name] 808 fd bar [type+name]
@@ -819,7 +819,7 @@ fn foo(a: A) { B { bar: a.<|> }; }
819struct A { foo: i64, bar: u32, baz: u32 } 819struct A { foo: i64, bar: u32, baz: u32 }
820struct B { x: (), y: f32, bar: u32 } 820struct B { x: (), y: f32, bar: u32 }
821fn f(foo: i64) { } 821fn f(foo: i64) { }
822fn foo(a: A) { B { bar: f(a.<|>) }; } 822fn foo(a: A) { B { bar: f(a.$0) }; }
823"#, 823"#,
824 expect![[r#" 824 expect![[r#"
825 fd foo [type+name] 825 fd foo [type+name]
@@ -832,7 +832,7 @@ fn foo(a: A) { B { bar: f(a.<|>) }; }
832struct A { foo: i64, bar: u32, baz: u32 } 832struct A { foo: i64, bar: u32, baz: u32 }
833struct B { x: (), y: f32, bar: u32 } 833struct B { x: (), y: f32, bar: u32 }
834fn f(foo: i64) { } 834fn f(foo: i64) { }
835fn foo(a: A) { f(B { bar: a.<|> }); } 835fn foo(a: A) { f(B { bar: a.$0 }); }
836"#, 836"#,
837 expect![[r#" 837 expect![[r#"
838 fd bar [type+name] 838 fd bar [type+name]
@@ -847,7 +847,7 @@ fn foo(a: A) { f(B { bar: a.<|> }); }
847 check_scores( 847 check_scores(
848 r#" 848 r#"
849struct WorldSnapshot { _f: () }; 849struct WorldSnapshot { _f: () };
850fn go(world: &WorldSnapshot) { go(w<|>) } 850fn go(world: &WorldSnapshot) { go(w$0) }
851"#, 851"#,
852 expect![[r#" 852 expect![[r#"
853 bn world [type+name] 853 bn world [type+name]
@@ -862,7 +862,7 @@ fn go(world: &WorldSnapshot) { go(w<|>) }
862 check_scores( 862 check_scores(
863 r#" 863 r#"
864struct Foo; 864struct Foo;
865fn f(foo: &Foo) { f(foo, w<|>) } 865fn f(foo: &Foo) { f(foo, w$0) }
866"#, 866"#,
867 expect![[r#" 867 expect![[r#"
868 st Foo [] 868 st Foo []