libraries: add ==0 or !=0 to expressions that depend on implicit conversion from byte to bool

This commit is contained in:
Irmen de Jong
2024-02-04 23:22:43 +01:00
parent 92527b4c1d
commit 1ca3f64bf0
19 changed files with 130 additions and 132 deletions
@@ -9,8 +9,6 @@ import kotlin.math.truncate
sealed class PtExpression(val type: DataType, position: Position) : PtNode(position) {
init {
if(type==DataType.BOOL)
throw IllegalArgumentException("bool should have become ubyte @$position")
if(type==DataType.UNDEFINED) {
@Suppress("LeakingThis")
when(this) {