diff options
author | Casey Primozic <[email protected]> | 2020-10-06 23:05:20 +0100 |
---|---|---|
committer | Casey Primozic <[email protected]> | 2020-10-06 23:05:20 +0100 |
commit | 56a8a7645f9d6c872e9598b5a2617805f387e2a6 (patch) | |
tree | be94bbbf4293f37d35d66092cbf9a6d9ebef2bd4 | |
parent | bf1043cac2f3cc2264d9fcda242f63616f4efa1b (diff) |
Bump chalk to use latest git to get fix
* Chalk very recently (like an hour ago) merged a fix that prevents rust analyzer from panicking. This allows it to be usable again for code that hits those situations. See #6134, #6145, Probably #6120
-rw-r--r-- | Cargo.lock | 20 | ||||
-rw-r--r-- | crates/hir_ty/Cargo.toml | 6 | ||||
-rw-r--r-- | crates/hir_ty/src/traits/chalk.rs | 12 | ||||
-rw-r--r-- | crates/hir_ty/src/traits/chalk/mapping.rs | 1 | ||||
-rw-r--r-- | editors/code/package.json | 2 |
5 files changed, 25 insertions, 16 deletions
diff --git a/Cargo.lock b/Cargo.lock index 49022502d..9c921902c 100644 --- a/Cargo.lock +++ b/Cargo.lock | |||
@@ -162,9 +162,8 @@ checksum = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822" | |||
162 | 162 | ||
163 | [[package]] | 163 | [[package]] |
164 | name = "chalk-derive" | 164 | name = "chalk-derive" |
165 | version = "0.30.0" | 165 | version = "0.32.0-dev.0" |
166 | source = "registry+https://github.com/rust-lang/crates.io-index" | 166 | source = "git+https://github.com/rust-lang/chalk.git?rev=ebe62c2bc46899a0a92eabb456b38ad2d40abbd0#ebe62c2bc46899a0a92eabb456b38ad2d40abbd0" |
167 | checksum = "a6696d18587b7470c1e357a3fa120a2b7e6ac95e91d5c408f087455f7dc31f8b" | ||
168 | dependencies = [ | 167 | dependencies = [ |
169 | "proc-macro2", | 168 | "proc-macro2", |
170 | "quote", | 169 | "quote", |
@@ -174,9 +173,8 @@ dependencies = [ | |||
174 | 173 | ||
175 | [[package]] | 174 | [[package]] |
176 | name = "chalk-ir" | 175 | name = "chalk-ir" |
177 | version = "0.30.0" | 176 | version = "0.32.0-dev.0" |
178 | source = "registry+https://github.com/rust-lang/crates.io-index" | 177 | source = "git+https://github.com/rust-lang/chalk.git?rev=ebe62c2bc46899a0a92eabb456b38ad2d40abbd0#ebe62c2bc46899a0a92eabb456b38ad2d40abbd0" |
179 | checksum = "8c9538918d3e1fd6edda042d717c969a4099af67a40372dfb0a00b45d3a5a946" | ||
180 | dependencies = [ | 178 | dependencies = [ |
181 | "chalk-derive", | 179 | "chalk-derive", |
182 | "lazy_static", | 180 | "lazy_static", |
@@ -184,9 +182,8 @@ dependencies = [ | |||
184 | 182 | ||
185 | [[package]] | 183 | [[package]] |
186 | name = "chalk-recursive" | 184 | name = "chalk-recursive" |
187 | version = "0.30.0" | 185 | version = "0.32.0-dev.0" |
188 | source = "registry+https://github.com/rust-lang/crates.io-index" | 186 | source = "git+https://github.com/rust-lang/chalk.git?rev=ebe62c2bc46899a0a92eabb456b38ad2d40abbd0#ebe62c2bc46899a0a92eabb456b38ad2d40abbd0" |
189 | checksum = "97ec8d95c808f2b540c39da889536e1ae0d15182107f61fe80000ec3a5c3959a" | ||
190 | dependencies = [ | 187 | dependencies = [ |
191 | "chalk-derive", | 188 | "chalk-derive", |
192 | "chalk-ir", | 189 | "chalk-ir", |
@@ -197,9 +194,8 @@ dependencies = [ | |||
197 | 194 | ||
198 | [[package]] | 195 | [[package]] |
199 | name = "chalk-solve" | 196 | name = "chalk-solve" |
200 | version = "0.30.0" | 197 | version = "0.32.0-dev.0" |
201 | source = "registry+https://github.com/rust-lang/crates.io-index" | 198 | source = "git+https://github.com/rust-lang/chalk.git?rev=ebe62c2bc46899a0a92eabb456b38ad2d40abbd0#ebe62c2bc46899a0a92eabb456b38ad2d40abbd0" |
202 | checksum = "f373dff4bcff66004424b72bcc56ae62889c21887c1cac875f083f69a7da4448" | ||
203 | dependencies = [ | 199 | dependencies = [ |
204 | "chalk-derive", | 200 | "chalk-derive", |
205 | "chalk-ir", | 201 | "chalk-ir", |
diff --git a/crates/hir_ty/Cargo.toml b/crates/hir_ty/Cargo.toml index ed1c911c2..15c536c89 100644 --- a/crates/hir_ty/Cargo.toml +++ b/crates/hir_ty/Cargo.toml | |||
@@ -17,9 +17,9 @@ ena = "0.14.0" | |||
17 | log = "0.4.8" | 17 | log = "0.4.8" |
18 | rustc-hash = "1.1.0" | 18 | rustc-hash = "1.1.0" |
19 | scoped-tls = "1" | 19 | scoped-tls = "1" |
20 | chalk-solve = { version = "0.30.0" } | 20 | chalk-solve = { git = "https://github.com/rust-lang/chalk.git", rev="ebe62c2bc46899a0a92eabb456b38ad2d40abbd0" } |
21 | chalk-ir = { version = "0.30.0" } | 21 | chalk-ir = { git = "https://github.com/rust-lang/chalk.git", rev="ebe62c2bc46899a0a92eabb456b38ad2d40abbd0" } |
22 | chalk-recursive = { version = "0.30.0" } | 22 | chalk-recursive = { git = "https://github.com/rust-lang/chalk.git", rev="ebe62c2bc46899a0a92eabb456b38ad2d40abbd0" } |
23 | 23 | ||
24 | stdx = { path = "../stdx", version = "0.0.0" } | 24 | stdx = { path = "../stdx", version = "0.0.0" } |
25 | hir_def = { path = "../hir_def", version = "0.0.0" } | 25 | hir_def = { path = "../hir_def", version = "0.0.0" } |
diff --git a/crates/hir_ty/src/traits/chalk.rs b/crates/hir_ty/src/traits/chalk.rs index 009b17a7f..980218162 100644 --- a/crates/hir_ty/src/traits/chalk.rs +++ b/crates/hir_ty/src/traits/chalk.rs | |||
@@ -330,6 +330,18 @@ impl<'a> chalk_solve::RustIrDatabase<Interner> for ChalkContext<'a> { | |||
330 | fn fn_def_name(&self, fn_def_id: chalk_ir::FnDefId<Interner>) -> String { | 330 | fn fn_def_name(&self, fn_def_id: chalk_ir::FnDefId<Interner>) -> String { |
331 | format!("fn_{}", fn_def_id.0) | 331 | format!("fn_{}", fn_def_id.0) |
332 | } | 332 | } |
333 | fn generator_datum( | ||
334 | &self, | ||
335 | _: chalk_ir::GeneratorId<Interner>, | ||
336 | ) -> std::sync::Arc<chalk_solve::rust_ir::GeneratorDatum<Interner>> { | ||
337 | todo!() | ||
338 | } | ||
339 | fn generator_witness_datum( | ||
340 | &self, | ||
341 | _: chalk_ir::GeneratorId<Interner>, | ||
342 | ) -> std::sync::Arc<chalk_solve::rust_ir::GeneratorWitnessDatum<Interner>> { | ||
343 | todo!() | ||
344 | } | ||
333 | } | 345 | } |
334 | 346 | ||
335 | pub(crate) fn program_clauses_for_chalk_env_query( | 347 | pub(crate) fn program_clauses_for_chalk_env_query( |
diff --git a/crates/hir_ty/src/traits/chalk/mapping.rs b/crates/hir_ty/src/traits/chalk/mapping.rs index d42f4bba9..140b20213 100644 --- a/crates/hir_ty/src/traits/chalk/mapping.rs +++ b/crates/hir_ty/src/traits/chalk/mapping.rs | |||
@@ -399,6 +399,7 @@ impl ToChalk for TypeCtor { | |||
399 | // this should not be reached, since we don't represent TypeName::Error with TypeCtor | 399 | // this should not be reached, since we don't represent TypeName::Error with TypeCtor |
400 | unreachable!() | 400 | unreachable!() |
401 | } | 401 | } |
402 | _ => todo!(), | ||
402 | } | 403 | } |
403 | } | 404 | } |
404 | } | 405 | } |
diff --git a/editors/code/package.json b/editors/code/package.json index 1f0e7550b..6a712a8a8 100644 --- a/editors/code/package.json +++ b/editors/code/package.json | |||
@@ -1048,4 +1048,4 @@ | |||
1048 | ] | 1048 | ] |
1049 | } | 1049 | } |
1050 | } | 1050 | } |
1051 | } \ No newline at end of file | 1051 | } |