Path: csiph.com!weretis.net!feeder9.news.weretis.net!panix!.POSTED.spitfire.i.gajendra.net!not-for-mail From: cross@spitfire.i.gajendra.net (Dan Cross) Newsgroups: comp.lang.c Subject: Re: Taming The Switch-Statement Date: Sat, 10 Oct 2026 19:03:59 -0000 (UTC) Organization: PANIX Public Access Internet and UNIX, NYC Message-ID: <11ae26v$obj$1@reader2.panix.com> References: <119qf6l$2rmg3$1@dont-email.me> <11addhr$1oakb$1@dont-email.me> <11aduuk$cjlv$1@dont-email.me> <20261010220212.000063fd@yahoo.com> Injection-Date: Sat, 10 Oct 2026 19:03:59 -0000 (UTC) Injection-Info: reader2.panix.com; posting-host="spitfire.i.gajendra.net:166.84.136.80"; logging-data="24947"; mail-complaints-to="abuse@panix.com" X-Newsreader: trn 4.0-test77 (Sep 1, 2010) Originator: cross@spitfire.i.gajendra.net (Dan Cross) Xref: csiph.com comp.lang.c:402891 In article <20261010220212.000063fd@yahoo.com>, Michael S wrote: >On Sat, 10 Oct 2026 20:08:20 +0200 >Janis Papanagnou wrote: > >> On 2026-10-10 15:11, bart wrote: >> > >> > Well, Algol 68 doesn't even have 'break'. For unusual control-flow >> > it needs goto. >> >> Yes. - And while "C" has 'goto' as well it also supports 'break' for >> some purposes; e.g. as a loop-exit, so it makes sense to reuse that >> keyword for other purposes as in 'switch' where it's been useful. >> > >After practicing C programming for more than 35 years I am deeply >convinced that reuse of the same 'break' keyword for loops and for >switch was a mistake. But then again, DRM did not have a benefit >of hindsight. Perhaps you mean "DMR", aka, Dennis Ritchie. - Dan C.