Newsgroups: comp.lang.c
From: g...@smoke.ARPA (Doug Gwyn )
Date: 25 Aug 88 16:16:29 GMT
Local: Thurs, Aug 25 1988 12:16 pm
Subject: Re: Explanation, please!
In article <6...@paris.ICS.UCI.EDU> schm...@bonnie.ics.uci.edu (Douglas C. Schmidt) writes:
- switch(count % 8) { - case 0: do { *to++ = *from++; - case 7: *to++ = *from++; - case 6: *to++ = *from++; - case 5: *to++ = *from++; - case 4: *to++ = *from++; - case 3: *to++ = *from++; - case 2: *to++ = *from++; - case 1: *to++ = *from++; - } while (--n > 0); - } -Now, much to my surprise, this is not only valid C++, it is also valid C! Could you explain why it shouldn't be? "case" labels are just a -It seems like the case 7-1 labels are actually nested inside the ?? "Thus"? Why would the labels go out of scope? They're -(should a break statement exit both the switch and the loop, or just one?!?!) A "break" applies to whatever the innermost container is. A "break" -Finally, Stroustrup asks the rhetorical question ``why would anyone It's about the fastest way to move arbitrarily-aligned data in You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||