home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.c      Meh, in C you gotta define EVERYTHING      243,242 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 241,408 of 243,242   
   Kaz Kylheku to pozz   
   Re: bugprone-switch-missing-default-case   
   22 Oct 25 18:13:41   
   
   From: 643-408-1753@kylheku.com   
      
   On 2025-10-22, pozz  wrote:   
   >   
   >  From here[1]:   
   >   
   >> Switch statements without a default case can lead to unexpected   
   >> behavior and incomplete handling of all possible cases. When a switch   
   >> statement lacks a default case, if a value is encountered that does   
   >> not match any of the specified cases, the program will continue   
   >> execution without any defined behavior or handling.   
   >   
   > Maybe I misunderstood that sentence caused by my bad English.   
      
   It is just slop written by someone who is new to the subject matter.   
      
   "defined behavior" is a radioactive term that you simply don't   
   use so carelessly, when documenting a C implementation.   
      
   --   
   TXR Programming Language: http://nongnu.org/txr   
   Cygnal: Cygwin Native Application Library: http://kylheku.com/cygnal   
   Mastodon: @Kazinator@mstdn.ca   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca