Use ty.for_debug

This commit is contained in:
Andy Leiserson authored and Jim Blandy committed 2025-04-09 08:15:47 -07:00
1 parent d223bb582f
commit be16f8ce18
2 files changed
+4 -3

No files matched your search

+2 -1
View File
@@ -614,7 +614,8 @@ impl<'a> ResolveContext<'a> {
TypeResolution::Value(bool)
} else {
return Err(ResolveError::IncompatibleOperands(format!(
"{op:?}({ty:?}, _)"
"{op:?}({:?}, _)",
ty.for_debug(types),
)));
}
}
+2 -2
View File
@@ -3185,7 +3185,7 @@ fn vector_logical_ops() {
"fn foo(a: vec2<bool>, b: vec2<bool>) {
let y = a && b;
}",
r#"error: Incompatible operands: LogicalAnd(Vector { size: Bi, scalar: Scalar { kind: Bool, width: 1 } }, _)
r#"error: Incompatible operands: LogicalAnd(vec2<bool>, _)
"#,
);
@@ -3194,7 +3194,7 @@ fn vector_logical_ops() {
"fn foo(a: vec2<bool>, b: vec2<bool>) {
let y = a || b;
}",
r#"error: Incompatible operands: LogicalOr(Vector { size: Bi, scalar: Scalar { kind: Bool, width: 1 } }, _)
r#"error: Incompatible operands: LogicalOr(vec2<bool>, _)
"#,
);