David Glasser06/08/2020, 5:03 PM
and friends) w.r.t. operator precedence. Do I just need to always parenthesize every sub-expression? I guess Kotlin doesn’t really do precedence levels of custom infix operators?
Joel06/08/2020, 5:26 PM
I believe that
columnA eq true and columnB eq false
have the same precedence because they are both method calls, so the compilter thinks you are trying to execute
which is obviously not correct.
(columnA eq true and columnB) eq false
meaning you should parenthesize everything but the first statement, but it can't hurt to also parenthesize the first statement if that looks good to you.
columnA eq true and (columnB eq false)
David Glasser06/08/2020, 5:29 PM
Joel06/08/2020, 5:31 PM