I'm getting a crash from the fuzzer, and #4202 seems like the most likely culprit.
What did you do, or what's a simple way to reproduce the bug?
This input:
class C(T:! type) {
fn F() {
data;
}
var data: {};
}
produces:
CHECK failure at toolchain/sem_ir/generic.cpp:84: value_block_id.is_valid(): Queried genericInstInDef3 in specific0 for {kind: ClassDecl, arg0: class0, arg1: block5, type: type(inst+8)} before it was resolved.
but:
class C(T:! type) {
fn F() {
x;
}
var data: {};
}
succeeds (printing diagnostics). The only difference is data vs. x in the body of F.
I've tried to minimize the input that triggers the failure. For example, making this non-generic by removing (T:! type) causes it to succeed.
What did you expect to happen?
No CHECK failure
What actually happened?
CHECK failure
Any other information, logs, or outputs that you want to share?
Description of the bug:
I'm getting a crash from the fuzzer, and #4202 seems like the most likely culprit.
What did you do, or what's a simple way to reproduce the bug?
This input:
produces:
but:
succeeds (printing diagnostics). The only difference is
data
vs.x
in the body ofF
.I've tried to minimize the input that triggers the failure. For example, making this non-generic by removing
(T:! type)
causes it to succeed.What did you expect to happen?
No CHECK failure
What actually happened?
CHECK failure
Any other information, logs, or outputs that you want to share?
Here is the Stack dump when it crashes:
...