Continue bool conversion fixing (#13751)
* continue fixing #13744 * improve style * improve test Co-authored-by: cooldome <ariabushenko@bk.ru>
This commit is contained in:
parent
e1e062197e
commit
764a81ca25
3 changed files with 20 additions and 2 deletions
|
|
@ -52,5 +52,12 @@ proc test_conv_to_bool =
|
|||
|
||||
|
||||
static:
|
||||
doAssert(bool(0) == false)
|
||||
doAssert(bool(-1) == true)
|
||||
doAssert(bool(2) == true)
|
||||
doAssert(bool(NaN) == true)
|
||||
doAssert(bool(0.0) == false)
|
||||
doAssert(bool(-0.0) == false)
|
||||
test_conv_to_bool()
|
||||
test_conv_to_bool()
|
||||
test_conv_to_bool()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue