Strict Equality Operator === before 6.2.3 was too strict

Prior to Lucee 6.0, the === operator only compared if the underlying java objects were the same object, which wasn’t very useful.

In Lucee 6, this was changed to match the expectation of comparing type and value

However, I recently discovered that it was comparing the underlying java types, rather than cfml types, so comparing numbers wouldn’t always work as expected.

Some Lucee functions may return an int and by default, numbers in Lucee are doubles, so ArrayLen([1,2,3]) === 3 would return false

This has been addressed in 6.2.3.34-SNAPSHOT

https://luceeserver.atlassian.net/browse/LDEV-5806

Breaking changes documents for 6.0 and 6.2 have been updated as well as the operators page in docs

5 Likes