about summary refs log tree commit diff
path: root/tests/coverage/branch/while.rs
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-12-03 17:27:10 +0100
committerGitHub <noreply@github.com>2024-12-03 17:27:10 +0100
commitc80286d35ea9d82e6d97be38d64c5d58258712b6 (patch)
treefde8bf0781ef87b348b968c2125ca6b653f8d5cd /tests/coverage/branch/while.rs
parent63231095d550c8e41abd6e7f29fee7e0592aa1e0 (diff)
parent2807ba77a0b8c22d1326a6bfef87b28942fe9ab7 (diff)
downloadrust-c80286d35ea9d82e6d97be38d64c5d58258712b6.tar.gz
rust-c80286d35ea9d82e6d97be38d64c5d58258712b6.zip
Rollup merge of #133779 - BoxyUwU:array_const_arg_infer_hir_id, r=compiler-errors
Use correct `hir_id` for array const arg infers

Fixes #133771

`self.next_id()` results in the `DefId` for the const argument, created from the hack introduced by #133468, having no `HirId` associated with it. This then results in an ICE in metadata encoding. Fixing this then results in *another* ICE where `encode_defs` was not skipping encoding `type_of` and other queries for `DefId`s when they correspond to a `ConstArgKind::Infer` node.

This only reproduces with a library crate as metadata is not encoded for binaries, and apparently we had 0 tests for `generic_arg_infer` for array lengths in a library crate so this was not caught :<

cc #133589 `@voidc`

r? `@compiler-errors` `@lcnr`
Diffstat (limited to 'tests/coverage/branch/while.rs')
0 files changed, 0 insertions, 0 deletions