File tree 2 files changed +19
-2
lines changed
2 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -45,12 +45,29 @@ jobs:
45
45
- name : Cache Dependencies
46
46
uses : Swatinem/rust-cache@ce325b60658c1b38465c06cc965b79baf32c1e72
47
47
48
- - name : Compile
48
+ - name : Bump opt-level
49
+ if : matrix.os == 'ubuntu-latest'
50
+ run : sed -i '/\[profile.dev]/a opt-level=1' Cargo.toml
51
+
52
+ - name : Compile (tests)
49
53
run : cargo test --no-run --locked
50
54
55
+ # It's faster to `test` before `build` ¯\_(ツ)_/¯
56
+ - name : Compile (rust-analyzer)
57
+ if : matrix.os == 'ubuntu-latest'
58
+ run : cargo build --quiet
59
+
51
60
- name : Test
52
61
run : cargo test -- --nocapture --quiet
53
62
63
+ - name : Run analysis-stats on rust-analyzer
64
+ if : matrix.os == 'ubuntu-latest'
65
+ run : target/${{ matrix.target }}/debug/rust-analyzer analysis-stats .
66
+
67
+ - name : Run analysis-stats on rust std library
68
+ if : matrix.os == 'ubuntu-latest'
69
+ run : target/${{ matrix.target }}/debug/rust-analyzer analysis-stats --with-deps $(rustc --print sysroot)/lib/rustlib/src/rust/library/std
70
+
54
71
# Weird targets to catch non-portable code
55
72
rust-cross :
56
73
if : github.repository == 'rust-lang/rust-analyzer'
Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ pub mod ext {
89
89
}
90
90
91
91
pub fn ty_name ( name : ast:: Name ) -> ast:: Type {
92
- ty_path ( ident_path ( & format ! ( "{ name}" ) ) )
92
+ ty_path ( ident_path ( & name. to_string ( ) ) )
93
93
}
94
94
pub fn ty_bool ( ) -> ast:: Type {
95
95
ty_path ( ident_path ( "bool" ) )
You can’t perform that action at this time.
0 commit comments