I got an error while performing a bitwise operation on two boolean values. Error :"Binary operator '|=' cannot be applied to two 'Bool' operands"
func checkAvailability(available:Bool) -> Bool{
var bChanged = false
bChanged |= available //"Binary operator '|=' cannot be applied to two 'Bool' operands"
return bChanged
}
Please any one help me to solve the problem...
bChanged = bChanged || available- OOPerbChanged = falsethen it's the same as just returningavailable. - DroppybChangedis aBoolvariable initialized with a certain value. Maybe we should have clarified such points. - OOPer