3 ms·
I didn't understand why the remark was there at all. Honestly | reminds me of sum types and it's the perfect choice here.
by spdionis 10y ago
I didn't understand why the remark was there at all. Honestly | reminds me of sum types and it's the perfect choice here.
- amochohan 10y agoThe reason I added this was because most developers are used to using a double pipe when writing code that has 'or' conditions. I understand the use of pipes for bitwise, but in this case if you read the code in the example, we're basically saying "if the exception is of type A or of type B", personally I'd be inclined to use || if I didn't already know the syntax.