aboutsummaryrefslogtreecommitdiff
path: root/crates/ide/src/syntax_highlighting/tests.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ide/src/syntax_highlighting/tests.rs')
-rw-r--r--crates/ide/src/syntax_highlighting/tests.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/crates/ide/src/syntax_highlighting/tests.rs b/crates/ide/src/syntax_highlighting/tests.rs
index 94f37d773..6cb955d29 100644
--- a/crates/ide/src/syntax_highlighting/tests.rs
+++ b/crates/ide/src/syntax_highlighting/tests.rs
@@ -36,6 +36,10 @@ impl Foo {
36 fn qux(&mut self) { 36 fn qux(&mut self) {
37 self.x = 0; 37 self.x = 0;
38 } 38 }
39
40 fn quop(&self) -> i32 {
41 self.x
42 }
39} 43}
40 44
41static mut STATIC_MUT: i32 = 0; 45static mut STATIC_MUT: i32 = 0;
@@ -87,6 +91,11 @@ fn main() {
87 let Foo { x: z, y } = Foo { x: z, y }; 91 let Foo { x: z, y } = Foo { x: z, y };
88 92
89 y; 93 y;
94
95 let mut foo = Foo { x, y: x };
96 foo.quop();
97 foo.qux();
98 foo.baz();
90} 99}
91 100
92enum Option<T> { 101enum Option<T> {