|| and && in julia are not normal functions. The reason for this is that they short circuit, and the only way to implement this without a macro is to have them not be a normal function. This has several consequences, including this. The other main one is that you can’t define a function called || that does something different. As a solution, you could definefunction or(a,b) =a||b end, which should achieve what you want. However, you also could probably use any which will probably be faster.