TechWhirl (TECHWR-L) is a resource for technical writing and technical communications professionals of all experience levels and in all industries to share their experiences and acquire information.
For two decades, technical communicators have turned to TechWhirl to ask and answer questions about the always-changing world of technical communications, such as tools, skills, career paths, methodologies, and emerging industries. The TechWhirl Archives and magazine, created for, by and about technical writers, offer a wealth of knowledge to everyone with an interest in any aspect of technical communications.
ROFLMAO!!!! OMG - this so needs to go into a uni curriculum somewhere as an
example of What Not To Do!
However, minus kudos for not having a routine that was commented thusly:
/* returns the value calculated from the state */
< still chuckling>
I was going to write 'chuckling still', but I have never seen a laugher
vaporiser / condenser for the fun stuff
-----Original Message-----
From: techwr-l-bounces+sh1448291904=gmail -dot- com -at- lists -dot- techwr-l -dot- com
[mailto:techwr-l-bounces+sh1448291904=gmail -dot- com -at- lists -dot- techwr-l -dot- com] On
Behalf Of Peter Neilson
Sent: Thursday, 5 May 2016 20:29
To: techwr-l -at- lists -dot- techwr-l -dot- com
Subject: Re: Satellite-killing software
On Thu, 05 May 2016 00:34:59 -0400, Keith Hood <bus -dot- write -at- gmail -dot- com> wrote:
> It's not Friday yet but what the heck . . . I saw a story about that
> Japanese satellite that failed in flight, on a site called
> hackaday.com.Apparently it malfunctioned after a software update went
> awry.
> I'm offering 5 to 2 they didn't bother to comment the code. Any takers?
I think they commented the code and then wrote more code based upon reading
the comments instead of the code. Only certain of the comments in code are
good enough to instill caution and perhaps inspire a search for deeper
understanding. My favorite one of those is this:
/*
* 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);
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Visit TechWhirl for the latest on content technology, content strategy and content development | http://techwhirl.com