Re: [OT] How to write unmaintainable code

new topic     » goto parent     » topic index » view thread      » older message » newer message
Roedy Green said...

Toilet Tubing

Comments at the top of procedures should use templates that are at least 15 lines long and make liberal use of blank lines. Here's a handy template:

/* 
/* Procedure Name: 
/* 
/* Original procedure name: 
/* 
/* Author: 
/* 
/* Date of creation: 
/* 
/* Dates of modification: 
/* 
/* Modification authors: 
/* 
/* Original file name: 
/* 
/* Purpose: 
/* 
/* Intent: 
/* 
/* Designation: 
/* 
/* Classes used: 
/* 
/* Constants: 
/* 
/* Local variables: 
/* 
/* Parameters: 
/* 
/* Date of creation: 
/* 
/* Purpose: 
*/ 

I like how "Purpose" and "Date of creation" are specified twice, while "Intent" is basically the same as "Purpose" and "Designation" seems entirely irrelevant.

I'm sure it goes without saying that while this template should certainly exist in the code, it should most definitely never be used. grin

-Greg

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu