Article View: comp.lang.c
Article #110Re: Taming The Switch-Statement
From: Johann 'Myrkraverk' Oskarsson
Date: Sat, 10 Oct 2026 13:58
Date: Sat, 10 Oct 2026 13:58
36 lines
2902 bytes
2902 bytes
On 10/10/2026 9:34 PM, Johann 'Myrkraverk' Oskarsson wrote: > On 10/10/2026 9:11 PM, bart wrote: >> because C was crazy enough to fall through to the else block unless >> 'break' was added! >> >> I guess everyone would still defend that choice (because for one >> person in a million it will be valuable feature). But it is CLEARLY >> wrong. > > It's been some years, so my memory is hazy, but the original C.P.L. > language "specification" or manual had all case: examples with an ex- > plicit return. I'm not even sure they had thought through exactly how > the semantics were meant to work, when they figured they couldn't make a > compiler after all. > > Then BCPL happened -- IIRC it happened before they had a working CPL > compiler -- and I expect that one had the fall through we're used to, > but bear in mind if you look at the most recent manual that it's not > the same compiler that predates B, and the rest is history. > > > You can of course ask Martin Richards, and maybe he still remembers if > the C.P.L. people had something else in mind. Good luck. Sort of. My memory was a bit off. See pages 122, and a bit onwards; then 127 for the "definition" which to me is inconclusive. https://www.ancientgeek.org.uk/CPL/CPL_Working_Papers.pdf Best wishes, and happy learning of the C.P.L. programming language. -- Johann | email: invalid -> com | http://www.myrkraverk.com/blog/ I'm not from the Internet, I just work there. | via Easynews.com https://bsky.app/profile/myrkraverk.bsky.social | for ( ;; ) _:; Federated at https://fed.brid.gy/bsky/myrkraverk.bsky.social
Technical Details
Message-ID:
<KvryS.192386$xra3.145895@fx16.ams4>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!peer04.ams4!peer.am4.highwinds-media.com!news.highwinds-media.com!fx16.ams4.POSTED!not-for-mailReferences:
<119qf6l$2rmg3$1@dont-email.me> <11ac0mi$19kfd$1@dont-email.me> <11ac2jv$1a84t$1@dont-email.me> <11ac783$1bkuo$1@kst.eternal-september.org> <11ad5eq$1l8hg$1@dont-email.me> <11ad9fg$cjm0$4@dont-email.me> <11addhr$1oakb$1@dont-email.me> <n9ryS.11350$Nbkf.9077@fx03.ams4>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!peer04.ams4!peer.am4.highwinds-media.com!news.highwinds-media.com!fx16.ams4.POSTED!not-for-mail MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Taming The Switch-Statement Newsgroups: comp.lang.c References: <119qf6l$2rmg3$1@dont-email.me> <11ac0mi$19kfd$1@dont-email.me> <11ac2jv$1a84t$1@dont-email.me> <11ac783$1bkuo$1@kst.eternal-september.org> <11ad5eq$1l8hg$1@dont-email.me> <11ad9fg$cjm0$4@dont-email.me> <11addhr$1oakb$1@dont-email.me> <n9ryS.11350$Nbkf.9077@fx03.ams4> Content-Language: en-US From: Johann 'Myrkraverk' Oskarsson <johann@myrkraverk.invalid> Organization: Watcom Pro Ltd. In-Reply-To: <n9ryS.11350$Nbkf.9077@fx03.ams4> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Lines: 36 Message-ID: <KvryS.192386$xra3.145895@fx16.ams4> X-Complaints-To: abuse@easynews.com X-Complaints-Info: Please be sure to forward a copy of ALL headers otherwise we will be unable to process your complaint properly. Date: Sat, 10 Oct 2026 21:58:02 +0800 X-Received-Bytes: 2717