Funny code again
-
Got some more code that I found amusing :) For example... {$DEFINE NoBeepCosItShitsDaveWhenListeningToMP3s} (that's delphi code by the way...) Senior Test Engineer GLI Australia www.gli.com.au
-
Got some more code that I found amusing :) For example... {$DEFINE NoBeepCosItShitsDaveWhenListeningToMP3s} (that's delphi code by the way...) Senior Test Engineer GLI Australia www.gli.com.au
LOL! cheers, Chris Maunder
-
Got some more code that I found amusing :) For example... {$DEFINE NoBeepCosItShitsDaveWhenListeningToMP3s} (that's delphi code by the way...) Senior Test Engineer GLI Australia www.gli.com.au
-
Got some more code that I found amusing :) For example... {$DEFINE NoBeepCosItShitsDaveWhenListeningToMP3s} (that's delphi code by the way...) Senior Test Engineer GLI Australia www.gli.com.au
Well, here is my favourites (found in my current bug-fixing project) 1) if (bVar1==FALSE) { bVar2=TRUE; } else { bVar2=FALSE; } 2) CChangesCacheListChangeStateElement * pElement=new CChangesCacheListChangeStateElement(); 3) aaand the greatest ! strPreparingString = CString("Datetime:") + tmTime.Format("%m/%d/%Y") + CString(" ") + tmTime.Format("%H:%M") + CString(" "); CString t_strTempTypeValue, t_strTypeValue; t_strTempTypeValue.Format("%x", btType); if(btType < 15) t_strTypeValue += "0"; t_strTempTypeValue.MakeUpper(); t_strTypeValue += t_strTempTypeValue; strPreparingString += CString("Type:0x") + t_strTypeValue; CString t_strTempUnitIDValue, t_strUnitIDValue; t_strTempUnitIDValue.Format("%x", wdUnitID); try { if(wdUnitID & 0xF000) throw 1; else t_strUnitIDValue += "0"; if(wdUnitID & 0x0F00) throw 1; else t_strUnitIDValue += "0"; if(wdUnitID & 0x00F0) throw 1; else t_strUnitIDValue += "0"; // if(wdUnitID & 0x000F) throw 1; else t_strUnitIDValue += "0"; } catch(...){ } t_strTempUnitIDValue.MakeUpper(); t_strUnitIDValue += t_strTempUnitIDValue; strPreparingString += CString(" Item:0x") + t_strUnitIDValue; strPreparingString += CString(" UnitName:") + strUnitName; ;P ;P ;P
-
Got some more code that I found amusing :) For example... {$DEFINE NoBeepCosItShitsDaveWhenListeningToMP3s} (that's delphi code by the way...) Senior Test Engineer GLI Australia www.gli.com.au
As studends we were forced always to use a big header for every function, even if it had just one comand: /********************************************************************************/ /* */ /* Funktion : */ /* Klasse : */ /* */ /********************************************************************************/ /* */ /* Autor : */ /* */ /* Beschreibung : */ /* */ /* Vorbedingung : */ /* Nachbedingung : */ /* */ /* Parameter : */ /* */ /* Rückgabewert : */ /* */ /********************************************************************************/ /* */ /* V | Datum | KZ | Anmerkung */ /*------------------------------------------------------------------------------*/ /* | | | */ /* | | | */ /* */ /********************************************************************************/ My solution was: #include "headerToMyFunction.h" int MyClass::MyFunction( int xy ) { ... } :-) Friedrich
-
As studends we were forced always to use a big header for every function, even if it had just one comand: /********************************************************************************/ /* */ /* Funktion : */ /* Klasse : */ /* */ /********************************************************************************/ /* */ /* Autor : */ /* */ /* Beschreibung : */ /* */ /* Vorbedingung : */ /* Nachbedingung : */ /* */ /* Parameter : */ /* */ /* Rückgabewert : */ /* */ /********************************************************************************/ /* */ /* V | Datum | KZ | Anmerkung */ /*------------------------------------------------------------------------------*/ /* | | | */ /* | | | */ /* */ /********************************************************************************/ My solution was: #include "headerToMyFunction.h" int MyClass::MyFunction( int xy ) { ... } :-) Friedrich