switch/default -- enum, want compiler error
Gary E. Miller
gem at rellim.com
Tue Apr 7 20:37:44 UTC 2026
Yo Hal!
On Mon, 06 Apr 2026 23:15:34 -0700
Hal Murray via devel <devel at ntpsec.org> wrote:
> default has several possible meanings.
>
> I'd like to get a compiler warning if I forgot to handle a case when
> switching on an enum. Is that possible?
I have not heard of such a thing. Would be nice. There is a possible
warning if there is no default, but nothing else.
RGDS
GARY
---------------------------------------------------------------------------
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
gem at rellim.com Tel:+1 541 382 8588
Veritas liberabit vos. -- Quid est veritas?
"If you can't measure it, you can't improve it." - Lord Kelvin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 283 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ntpsec.org/pipermail/devel/attachments/20260407/37df01a7/attachment.bin>
More information about the devel
mailing list