| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | writing REXX DLL`s |
Excerpted from message dated 01-18-97, Thomas Seeling to Jonathan De
Boyne Pollard:
JdBP> if (!terminating) {
JdBP> } else {
TS>I don't think it is good style to handle both cases of a boolean
>decision and begin with the negated part. Probably the compiler can
>optimize it, but I wouldn't trust this :)
TS>if (terminating) {}
>else {}
TS>is clearer, although your style fits the causality better :-)
Hi Thomas--
Shades of the Dijkstra "goto is harmful" fallacy and his
"more lucid
code!"
I learned many years ago that, for best performance, one should
always put the most likely case first (even if it is the negative case).
How can an optimizer know which case is the most likely? I believe that
one uses comments to make things clearer if necessary.
Regards,
--Murray
___
* MR/2 2.25 #120 * Which direction is forward?
--- Maximus/2 2.02
* Origin: OS/2 Shareware BBS, telnet://bbs.os2bbs.com (1:109/347)SEEN-BY: 50/99 54/99 270/101 620/243 625/110 160 711/401 413 430 808 934 SEEN-BY: 712/311 407 505 506 517 623 624 704 713/317 800/1 @PATH: 109/347 18 7 396/1 270/101 712/624 711/934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.