View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0031492||2.x IDE Bugs||General||Public||2019-11-15 10:52||2019-11-15 14:50|
|Reporter||Alice||Assigned To||Russell Kay|
|Priority||Medium||Severity||C - General||Reproducibility||100%|
|Status||Resolved||Resolution||No Change Required|
|Platform||Windows||OS||Windows 10||OS Version|
|Target Version||Fixed in Version|
|Summary||0031492: Functions: Boolean variables are treated as "numbers" by is_bool() and typeof()|
When checking a boolean variable with the functions is_bool() and typeof(), the variable is recognised as a number instead of a boolean, as you can see in the attached screenshot.
You actually have to do an expression which results in a boolean in order to get "bool" to be returned, e.g. "typeof(1==1)". However, the manual makes no mention that you can write expressions in this function, and does say it should determine the variable passed-in, as we were trying.
Boolean variables are identified as such by these functions.
|Steps To Reproduce||1-Launch the IDE|
2-Open the project attached
3-Run the project
4-Observe the issue
|Tags||No tags attached.|
|2.x IDE Found In||126.96.36.1995|
|2.x Runtime Found In||188.8.131.525|
|2.x IDE Verified In|
|2.x Runtime Verified In|