3 ms·
In rule 5 (about assertions), why the comparison to true? Why is "if (<boolean expression> == true)" preferable to "if (<boolean expresson>)"?
by geophile 10y ago
In rule 5 (about assertions), why the comparison to true? Why is "if (<boolean expression> == true)" preferable to "if (<boolean expresson>)"?
- Udo 10y agoI assume it's a habit to make sure you communicate to the type checker: "I expect this expression to be boolean".