Click here to Skip to main content
12,076,669 members (46,294 online)

Welcome to the Lounge

   

For lazing about and discussing anything in a software developer's life that takes your fancy except programming questions.

Technical discussions are encouraged, but click here to ask your programming question.

The Lounge is rated PG. If you're about to post something you wouldn't want your kid sister to read then don't post it. No flame wars, no abusive conduct, no programming questions and please don't post ads.
 
GeneralDoes this language feature seem strange to anyone else? Pin
lewax0020-Mar-13 13:58
memberlewax0020-Mar-13 13:58 
GeneralRe: Does this language feature seem strange to anyone else? Pin
PIEBALDconsult20-Mar-13 14:43
memberPIEBALDconsult20-Mar-13 14:43 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0020-Mar-13 15:00
memberlewax0020-Mar-13 15:00 
GeneralRe: Does this language feature seem strange to anyone else? Pin
AspDotNetDev20-Mar-13 15:04
protectorAspDotNetDev20-Mar-13 15:04 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0020-Mar-13 15:11
memberlewax0020-Mar-13 15:11 
GeneralRe: Does this language feature seem strange to anyone else? Pin
PIEBALDconsult20-Mar-13 15:17
memberPIEBALDconsult20-Mar-13 15:17 
GeneralRe: Does this language feature seem strange to anyone else? Pin
Matthew Faithfull20-Mar-13 15:10
memberMatthew Faithfull20-Mar-13 15:10 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0020-Mar-13 15:13
memberlewax0020-Mar-13 15:13 
But in C++ (if I remember correctly), all integer types are implicitly convertible to enum. Then 0 assignment becomes expected behavior. In a language that explicitly prevents this, having one magic value that works does not make sense to me.

Edit: Also, it doesn't work for other classes or structs either, so why should enum be special?
GeneralRe: Does this language feature seem strange to anyone else? Pin
Matthew Faithfull20-Mar-13 15:29
memberMatthew Faithfull20-Mar-13 15:29 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0020-Mar-13 15:39
memberlewax0020-Mar-13 15:39 
GeneralRe: Does this language feature seem strange to anyone else? Pin
Matthew Faithfull20-Mar-13 16:10
memberMatthew Faithfull20-Mar-13 16:10 
GeneralRe: Does this language feature seem strange to anyone else? Pin
Mike Winiberg21-Mar-13 23:14
memberMike Winiberg21-Mar-13 23:14 
GeneralRe: Does this language feature seem strange to anyone else? Pin
AspDotNetDev20-Mar-13 14:56
protectorAspDotNetDev20-Mar-13 14:56 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0020-Mar-13 15:06
memberlewax0020-Mar-13 15:06 
GeneralRe: Does this language feature seem strange to anyone else? Pin
AspDotNetDev20-Mar-13 15:09
protectorAspDotNetDev20-Mar-13 15:09 
GeneralRe: Does this language feature seem strange to anyone else? Pin
jschell21-Mar-13 11:04
memberjschell21-Mar-13 11:04 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0021-Mar-13 11:27
memberlewax0021-Mar-13 11:27 
GeneralRe: Does this language feature seem strange to anyone else? Pin
César de Souza22-Mar-13 1:43
memberCésar de Souza22-Mar-13 1:43 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0022-Mar-13 11:58
memberlewax0022-Mar-13 11:58 
GeneralRe: Does this language feature seem strange to anyone else? Pin
englebart22-Mar-13 3:26
memberenglebart22-Mar-13 3:26 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0022-Mar-13 11:41
memberlewax0022-Mar-13 11:41 
GeneralRe: Does this language feature seem strange to anyone else? Pin
RafagaX22-Mar-13 7:40
memberRafagaX22-Mar-13 7:40 
GeneralRe: Does this language feature seem strange to anyone else? Pin
Chadwick Posey22-Mar-13 8:48
memberChadwick Posey22-Mar-13 8:48 
GeneralRe: Does this language feature seem strange to anyone else? Pin
lewax0022-Mar-13 11:45
memberlewax0022-Mar-13 11:45 
GeneralReading Code Pin
Kyudos20-Mar-13 12:22
memberKyudos20-Mar-13 12:22 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web01 | 2.8.160208.1 | Last Updated 12 Feb 2016
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid