[Vala] Bitwise and (c &) in Vala

Hello I'd need to make some bitwise checks on a variable, but doing
something like:

 if (condition & MyClass.ENUM_VALUE_1)
   condition |= MyClass.ENUM_VALUE_2;

outputs me: "error : Condition must be boolean".

How to continue?

The same problems happens using the bitwise or (|).


PS: I'm just new to Vala :P

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]