Click here to Skip to main content
14,659,318 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
 
GeneralRe: Jira, Zephyr, Hmmm.... Pin
glennPattonInThePubAgain!9-Apr-18 22:02
professionalglennPattonInThePubAgain!9-Apr-18 22:02 
GeneralRe: Jira, Zephyr, Hmmm.... Pin
Mark Parity10-Apr-18 0:19
MemberMark Parity10-Apr-18 0:19 
GeneralRe: Jira, Zephyr, Hmmm.... Pin
glennPattonInThePubAgain!10-Apr-18 0:42
professionalglennPattonInThePubAgain!10-Apr-18 0:42 
GeneralRe: Jira, Zephyr, Hmmm.... Pin
Mark Parity10-Apr-18 0:54
MemberMark Parity10-Apr-18 0:54 
GeneralRadio procedure Pin
Eytukan9-Apr-18 20:54
MemberEytukan9-Apr-18 20:54 
GeneralRe: Radio procedure Pin
CodeWraith9-Apr-18 21:50
MemberCodeWraith9-Apr-18 21:50 
GeneralRe: Radio procedure Pin
den2k889-Apr-18 22:39
professionalden2k889-Apr-18 22:39 
GeneralWorst use of var I've seen... Pin
Sander Rossel9-Apr-18 19:19
professionalSander Rossel9-Apr-18 19:19 
So I'm not here to start a holy wvar, but this must be the worst use of var I've ever come across.
var dossier = GetDossier(id);
Three guesses what type dossier has?

Trick question, three guesses isn't enough.
It's actually dynamic and going into GetDossier tells me it can be four different types (or null)! Sigh | :sigh:
There's actually a switch with some magic number that returns a different model on 1, 2, 3 and 4...

Come to think of it, not only the var is very misleading, it's a bad case of dynamic as well Laugh | :laugh:

Not the best code I've come across Sigh | :sigh:

GeneralRe: Worst use of var I've seen... Pin
CodeWraith9-Apr-18 19:31
MemberCodeWraith9-Apr-18 19:31 
GeneralRe: Worst use of var I've seen... Pin
HobbyProggy9-Apr-18 19:34
professionalHobbyProggy9-Apr-18 19:34 
GeneralRe: Worst use of var I've seen... Pin
Foothill10-Apr-18 3:09
professionalFoothill10-Apr-18 3:09 
GeneralRe: Worst use of var I've seen... Pin
Jörgen Andersson9-Apr-18 20:33
professionalJörgen Andersson9-Apr-18 20:33 
GeneralRe: Worst use of var I've seen... Pin
Sander Rossel9-Apr-18 23:52
professionalSander Rossel9-Apr-18 23:52 
GeneralRe: Worst use of var I've seen... Pin
Munchies_Matt9-Apr-18 20:40
MemberMunchies_Matt9-Apr-18 20:40 
GeneralRe: Worst use of var I've seen... Pin
Sander Rossel9-Apr-18 21:50
professionalSander Rossel9-Apr-18 21:50 
GeneralRe: Worst use of var I've seen... Pin
#realJSOP9-Apr-18 23:21
mva#realJSOP9-Apr-18 23:21 
GeneralRe: Worst use of var I've seen... Pin
Sander Rossel9-Apr-18 23:29
professionalSander Rossel9-Apr-18 23:29 
GeneralRe: Worst use of var I've seen... Pin
Eytukan9-Apr-18 20:43
MemberEytukan9-Apr-18 20:43 
GeneralRe: Worst use of var I've seen... Pin
OriginalGriff9-Apr-18 21:32
mveOriginalGriff9-Apr-18 21:32 
GeneralRe: Worst use of var I've seen... Pin
Sander Rossel9-Apr-18 21:49
professionalSander Rossel9-Apr-18 21:49 
GeneralRe: Worst use of var I've seen... Pin
HobbyProggy9-Apr-18 21:56
professionalHobbyProggy9-Apr-18 21:56 
GeneralRe: Worst use of var I've seen... Pin
OriginalGriff9-Apr-18 22:02
mveOriginalGriff9-Apr-18 22:02 
GeneralRe: Worst use of var I've seen... Pin
Sander Rossel9-Apr-18 23:49
professionalSander Rossel9-Apr-18 23:49 
GeneralRe: Worst use of var I've seen... Pin
HobbyProggy9-Apr-18 23:56
professionalHobbyProggy9-Apr-18 23:56 
GeneralRe: Worst use of var I've seen... Pin
Nathan Minier10-Apr-18 1:35
professionalNathan Minier10-Apr-18 1:35 

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.