Wait - behind the scenes

Does using the wait clause with a binary condition cause busy waiting? or does it somehow create an event for any change in the objects mentioned in the condition and check the truth value of the condition for that change?
Example:
If I write

wait(bit_func());

and the body of bit_func includes a print to log, and a calculation of a condition;
Would I see the log print many times, because the function is called repeatedly until yielding 1 (true)?

In reply to Avi_311:

The answer depends on whether bit_func() is a method of a class or not.

If bit_func() is not a class method, bit_func() gets called once when encountering the wait statement. If it returns true, the process continues to the next statement. If it returns false, the process suspends permanently. This is because the only thing that could cause re-evaluation of a wait(expression) or @(expression) is if one of the operands of that expression changes. Since your function has no input arguments, there are no operands that could change.

If bit_func() is a method of a class, then all the properties of that class are considered operands of that method. So changing a class property would cause that method to re-evaluate.

Regarding your last question, it can be difficult to predict how many times the function gets called for each change when there ae multiple changes in operands, or multiple 0-delay changes on the same operand. So I would not write any code that depends on the number of times it gets called.

To summarize, any object that appears in the expression is watched for changes, and any changes cause reevaluation of the expression.
If there is a function as above, except with a parameter

wait(bitfunc(param))

then param will be watched for changes.
If bit_method is a class method, then every field of the calling class is watched for changes.
Does this apply only in a case like this:

wait(some_class.bit_method());

Or also like this

wait(bit_method());

Where the wait clause is written inside one of the other class methods, and bit_method is local?