History

tcctest: One more signed zero test

This also checks that -(-0.0) is +0.0.

Michael Matz committed 12 years ago

Commit f42a02e1 parent 05c9b761 file · +6 −0Browse files

Unified · Split

tests/tcctest.c+6−0
@@ -1721,6 +1721,12 @@ void prefix ## signed_zeros(void) \ · 1720 unmodified lines
17211721 1.0 / x != 1.0 / p);\
17221722 else\
17231723 printf ("x != +y; this is wrong!\n");\
1724+ p = -y;\
1725+ if (x == p)\
1726+ printf ("Test 1.0 / x != 1.0 / -y returns %d (should be 0).\n",\
1727+ 1.0 / x != 1.0 / p);\
1728+ else\
1729+ printf ("x != -y; this is wrong!\n");\
17241730 }\
17251731 void prefix ## test(void)\
17261732 {\

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t