IWETHEY v. 0.3.0 | TODO
1,095 registered users | 0 active users | 0 LpH | Statistics
Login | Create New User
IWETHEY Banner

Welcome to IWETHEY!

New That's ANSI C?!?
ANSI C compilers I've run across recently wouldn't allow you to put a
case
label inside of a block (i.e. inside of an open curly brace).

I know ANSI C++ won't let you...
jb4
"We continue to live in a world where all our know-how is locked into binary files in an unknown format. If our documents are our corporate memory, Microsoft still has us all condemned to Alzheimer's."
Simon Phipps, SUN Microsystems
Expand Edited by jb4 May 14, 2003, 01:46:33 PM EDT
New That's ANSI C?!? ... YES
I just tried it undef GNU C++, GNU C and Solaris C++. Duff's device works fine under all of them.

(NOTE: I had to change "register n" to "register int n" for it to work in C++).
--
-- Jim Weirich jweirich@one.net [link|http://w3.one.net/~jweirich|http://w3.one.net/~jweirich]
---------------------------------------------------------------------
"Beware of bugs in the above code; I have only proved it correct,
not tried it." -- Donald Knuth (in a memo to Peter van Emde Boas)
Expand Edited by JimWeirich May 14, 2003, 01:58:08 PM EDT
New Re: That's ANSI C?!?
No, it's antsy C!

Took me a while to figure out what the hell it was for the first time I saw it.
-drl
     Cringely on Refactoring - (tjsinclair) - (41)
         He's still skirting the real issues to make his "point". - (admin) - (39)
             Good point - (tjsinclair) - (38)
                 Do I use unit tests? - (admin) - (34)
                     Apparently my question sounded dumber than it actually was - (tjsinclair) - (33)
                         Lessons to be gleaned: - (admin) - (16)
                             Great stuff! - (tjsinclair) - (2)
                                 Re: Great stuff! - (admin)
                                 C++ unit testing - sounds painful - (tuberculosis)
                             More: - (admin) - (1)
                                 Code coverage - (Simon_Jester)
                             How does JUnit (and the like) deal with web pages? - (drewk) - (5)
                                 Not really specific to PHP. - (admin) - (3)
                                     Also from that page - (drewk) - (2)
                                         HttpUnit is more useful for integration testing. - (admin)
                                         We use PHPUnit where I work. - (static)
                                 I'm experimenting with testing dynamic content ... - (JimWeirich)
                             Can I quote this thread? - (tjsinclair) - (4)
                                 Even better: - (admin) - (2)
                                     No, you can't use my comments - (drewk)
                                     Thanks! - (tjsinclair)
                                 A TDD Example - (JimWeirich)
                         Ooh, he left out the ^ - (tuberculosis) - (15)
                             That's just evil to the core. :-) -NT - (ChrisR) - (1)
                                 It's C++, what do you expect? -NT - (tuberculosis)
                             I would only use that if it were properly commented. -NT - (static) - (12)
                                 I'd probably never use it at all - (tuberculosis) - (11)
                                     Its a cool parlor trick... - (jb4) - (10)
                                         Not even really a C++ issue as such, is it? - (deSitter) - (9)
                                             Its a Duff Device - (tuberculosis) - (5)
                                                 Yep - it's assembler in C -NT - (deSitter) - (4)
                                                     Most ASM Languages have a SWAP instruction. -NT - (ChrisR) - (3)
                                                         Yes, not my point - (deSitter) - (1)
                                                             And my point... - (ChrisR)
                                                         SWAP? - (JimWeirich)
                                             That's ANSI C?!? - (jb4) - (2)
                                                 That's ANSI C?!? ... YES - (JimWeirich)
                                                 Re: That's ANSI C?!? - (deSitter)
                 Re: Good point - (JimWeirich) - (2)
                     Another good point - (admin) - (1)
                         Me too. - (static)
         FWIW, Squeak is undergoing a huge refactoring effort - (tuberculosis)

In the arms of a jungle animal instinct.
78 ms