• Want to receive the latest contracting news and advice straight to your inbox? Sign up to the ContractorUK newsletter here. Every sign up will also be entered into a draw to WIN £100 Amazon vouchers!

Unusual Code Comments

Bod

More time posting than coding
Joined
Oct 31, 2007
Messages
279
Likes received
5
Thanks received
0
Location
Pushing the envelope
Just came across this at the end of an overnight housekeeping routine in a client's source code :

* This is the End, beautiful friend....
QUIT

Made me smile... (and one of my favourite songs)

Before checking back in and compiling, I have since added :
* The blue bus.... Is calling us....

slightly unprofessional I know, but WTF, it's Friday.

Any more code comments out there worthy of note ?
 
Last edited: 11:30
Presumably developed using DOORS.
 
Richard is a ******* Idiot.

Richard is a ******* Idiot.

Code:
    /// <summary>
    /// Class used to work around Richard being a ******* idiot
    /// </summary>
    /// <remarks>
    /// The point of this is to work around his poor design so that paging will 
    /// work on a mobile control. The main problem is the BindCompany() method, 
    /// which he hoped would be able to do everything. I hope he dies.
 
You are not expected to understand this.

You are not expected to understand this.

Code:
	/*
	 * Switch to stack of the new process and set up
	 * his segmentation registers.
	 */
	retu(rp->p_addr);
	sureg();
	/*
	 * If the new process paused because it was
	 * swapped out, set the stack level to the last call
	 * to savu(u_ssav).  This means that the return
	 * which is executed immediately after the call to aretu
	 * actually returns from the last routine which did
	 * the savu.
	 *
	 * You are not expected to understand this.
	 */
	if(rp->p_flag&SSWAP) {
		rp->p_flag =& ~SSWAP;
		aretu(u.u_ssav);
	}
	/*
	 * The value returned here has many subtle implications.
	 * See the newproc comments.
	 */
	return(1);
 
I love finding blocks of commented out code:

Code:
	ASSERT(0);
	// "Do not use" says Alan - "Why not?" says everyone else!
/*
....
*/
 
It doesnt work.

It doesnt work.

Code:
# code below replaces code above - any problems?
 # yeah, it doesn't ******* work
.
 
It wasn't my fault.

It wasn't my fault.

Code:
// I am not responsible of this code.
// They made me write it, against my will.
 
Happy Debugging

Happy Debugging

Code:
#define TRUE FALSE
//Happy debugging suckers
 

Advertisers

Back
Top