web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :

Priority of Boolean operations

Volodymyr Giginiak Profile Picture Volodymyr Giginiak Microsoft Employee
In X++ Boolean && and || operations have the same priority. That is not the case in other languages where && has higher priority than ||. So adding additional parenthesis to make sure that code works as expected is a good idea.
Example: (true || false && false) will be evaluated to false in X++, but in C# it will be evaluated to true.

This was originally posted here.

Comments

*This post is locked for comments