Click here to Skip to main content
13,765,264 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: Repurposing VarChar columns Pin
Eddy Vluggen28-May-18 1:48
professionalEddy Vluggen28-May-18 1:48 
GeneralRe: Repurposing VarChar columns Pin
Jörgen Andersson28-May-18 1:49
protectorJörgen Andersson28-May-18 1:49 
GeneralRe: Repurposing VarChar columns Pin
PeejayAdams23-May-18 6:35
memberPeejayAdams23-May-18 6:35 
GeneralRe: Repurposing VarChar columns Pin
GuyThiebaut24-May-18 22:10
professionalGuyThiebaut24-May-18 22:10 
GeneralRe: Repurposing VarChar columns Pin
David A. Gray25-Jun-18 12:05
memberDavid A. Gray25-Jun-18 12:05 
GeneralRe: Repurposing VarChar columns Pin
GuyThiebaut25-Jun-18 21:31
professionalGuyThiebaut25-Jun-18 21:31 
GeneralRe: Repurposing VarChar columns Pin
David A. Gray26-Jun-18 7:23
memberDavid A. Gray26-Jun-18 7:23 
Questionreassigning static variable Pin
Eytukan22-May-18 2:02
memberEytukan22-May-18 2:02 
static object s_obj = new object();

then in some function,

void func()
{
object obj = new object();
s_obj = obj;
}


Honestly, I have never seen such a code before. Dead | X| When someone does this, what actually happens to the memory, statically allocated to s_obj, initially? It's left hanging on the air without any reference ?

Starting to think people post kid pics in their profiles because that was the last time they were cute - Jeremy Falcon.

AnswerRe: reassigning static variable Pin
KarstenK22-May-18 2:11
mvpKarstenK22-May-18 2:11 
GeneralRe: reassigning static variable Pin
Eytukan22-May-18 2:12
memberEytukan22-May-18 2:12 
GeneralRe: reassigning static variable Pin
Eddy Vluggen22-May-18 2:37
professionalEddy Vluggen22-May-18 2:37 
GeneralRe: reassigning static variable Pin
Eytukan22-May-18 2:39
memberEytukan22-May-18 2:39 
GeneralRe: reassigning static variable PinPopular
Richard Deeming22-May-18 3:35
mvpRichard Deeming22-May-18 3:35 
GeneralIsomorphic Git Pin
Brisingr Aerowing16-May-18 20:24
professionalBrisingr Aerowing16-May-18 20:24 
GeneralRe: Isomorphic Git Pin
GenJerDan16-May-18 20:41
memberGenJerDan16-May-18 20:41 
GeneralRe: Isomorphic Git Pin
Marc Clifton17-May-18 4:38
protectorMarc Clifton17-May-18 4:38 
GeneralRe: Isomorphic Git Pin
Super Lloyd18-May-18 21:12
memberSuper Lloyd18-May-18 21:12 
GeneralRe: Isomorphic Git Pin
megaadam21-May-18 6:41
professionalmegaadam21-May-18 6:41 
GeneralRe: Isomorphic Git Pin
Super Lloyd21-May-18 7:16
memberSuper Lloyd21-May-18 7:16 
GeneralRe: Isomorphic Git Pin
Richard Deeming21-May-18 8:23
mvpRichard Deeming21-May-18 8:23 
GeneralRe: Isomorphic Git Pin
Super Lloyd21-May-18 8:47
memberSuper Lloyd21-May-18 8:47 
GeneralIs it my fault? Pin
PIEBALDconsult14-May-18 15:31
protectorPIEBALDconsult14-May-18 15:31 
GeneralRe: Is it my fault? Pin
Super Lloyd14-May-18 17:51
memberSuper Lloyd14-May-18 17:51 
GeneralRe: Is it my fault? Pin
Jon McKee14-May-18 19:17
professionalJon McKee14-May-18 19:17 
GeneralRe: Is it my fault? Pin
Eddy Vluggen15-May-18 2:01
professionalEddy Vluggen15-May-18 2:01 

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 | Cookies | Terms of Service
Web04-2016 | 2.8.181114.1 | Last Updated 15 Nov 2018
Copyright © CodeProject, 1999-2018
All Rights Reserved.
Layout: fixed | fluid