V9014¶
- Code
V9014
- Message
String operation operand encoding does not match expected encoding
The VM detected a string operation whose operand encoding (1 for STRING,
2 for WSTRING) does not match the destination’s declared encoding.
Mixing STRING and WSTRING is a compile error
(P4034), whether the two meet in an
assignment or as the operands of one operation. A program compiled by
ironplcc therefore does not reach this trap. Reaching it means one of:
A compiler bug that emits a string opcode whose source and destination disagree on encoding.
A tampered or hand-crafted ``.iplc`` file whose constant pool, data region headers, or temp buffer slots disagree on encoding.
The runtime check is the defense-in-depth layer: even if a static check slips, the trap fires before silently corrupting data.
This error indicates a bug in the IronPLC compiler or VM, or a corrupted
.iplc file — not a mistake in the program being run.
Report this as a bug at https://github.com/ironplc/ironplc/issues with the
.iplc file and the source program that produced it.
Think IronPLC is wrong about this?
If you believe this diagnostic is incorrect, open an issue on GitHub with a small sample that demonstrates the problem.