diff options
| author | _ov4 <ov4@ov4.org> | 2026-10-22 15:04:13 +0000 |
|---|---|---|
| committer | _ov4 <ov4@ov4.org> | 2026-10-22 15:21:14 +0000 |
| commit | 8802a5d740d6cff29e473e7e0507b6a6d40a55e4 (patch) | |
| tree | 135438ed78045a0336f40bbb54db0880777b22a8 /lib | |
| parent | 498a01534a4ffe825f84fd1b6aecbde5f5fde09c (diff) | |
fix(codegen): name both operand types in invalid operator diagnostics
Updates the operator-global-errors and string-type-mismatch expectations
to the new "Operator X cannot be applied to A and B" wording.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/CodeGen/TypeCheckGen.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/TypeCheckGen.cc b/lib/CodeGen/TypeCheckGen.cc index 575fc04..ef079b7 100644 --- a/lib/CodeGen/TypeCheckGen.cc +++ b/lib/CodeGen/TypeCheckGen.cc @@ -111,8 +111,8 @@ Value *CodeGen::emitUserKindBinaryOp(int Op, Value *L, const TypeInfo *LT, const char *RName = RT ? RT->Name.c_str() : "?"; if ((LT && LT->isRecord()) || (RT && RT->isRecord())) { - reportError("Operator %s cannot be applied to a record value (type %s)", - operatorSpelling(Op).c_str(), (LT && LT->isRecord()) ? LName : RName); + reportError("Operator %s cannot be applied to %s and %s", + operatorSpelling(Op).c_str(), LName, RName); return nullptr; } |
