|
PaulMmn wrote: > >Of course, if you haven't seen COBOL's ALTER GOTO, you don't know what you >are > >missing. The ALTER GOTO branches to different locations based on the value > >of a > >variable. The more obscure the variable, the higher your Obfuscation Factor. > > > >Of course, COBOL is a much superior language to RPG (<vbg>). > >Ducking before the incoming arrive, > >Bob Larkin > > Then there was the ALTER verb on the old IBM/1130: > > ALTER paragraph-name-1 TO PROCEED TO paragraph-name-2 > ... > PARAGRAPH-NAME-1. > GOTO PARAGRAPH-NAME-7. > PARAGRAPH-NAME-4. > ... > PARAGRAPH-NAME-2. > ... > PARAGRAPH-NAME-7. > ... > > It was self-modifying code. The target of the ALTER statement was a > paragraph that contained a single statement: the GOTO. Paragraph-name-2 > was any other paragraph name in the program. > > No matter what the compile listing looked like, the code could change > itself to branch all over the place! Quick, efficient (I think it > translated into a direct branch in the executable code), and a bear to > debug! > > I only used it in one program (just to prove I could do it). > > Paul, I think you touched on the point at hand. What was the cost per hour to have an 1130 and compare that to the cost per hour for a programmer. When I was learning to write code for a 360, if I didn't spend enough "man hours" to properly check my code for an errant loop, I'd get horse whipped! :) The times they are a changing ... Incredibly tight code has given way to "readability". Shift to reduce higher cost. OnRead(UncontrollableRant) .... That's a new JAVA function ;-) UncontrollableRant{ I don't even have a clue as to the price/performance of an 1130 compared to the least expense 400 today, let's say better than ten, maybe twenty times, could even be higher! (I've got a PIM with more power than that 4K programmable 3741 that cost 10x as much) What cost someone $2000 in hardware then can be had for $20 now. So let's talk labor costs. What could be had for $10 then is >$100 now. Way back when, I read statistics of 70-80% of all software dollars were spent on maintenance. "Readability" became a BIG factor. Structuring code is a methodology to reduce that percentage. It's not the LAW just a good idea. :) Should I walk into a shop my first question is not "Structured code?" it's "What's the shop standard, if any?" In either event I think to myself "I hope they kept consistant in whatever they did." IMHO, consistancy would reduce the understanding curve more than strict adherance to "todays" structure dogma. (Unless of course they were consistant with sticking to "todays" dogma ;-) ) Pick a time frame: Top down! HIPO! SAA! Information Flow! GOTO's are God! GOTO's are the Devil! CABxx are the Devil in disguise! LEAVE exists to avoid the shame of coding a GOTO! ITER is a way the screw the next guy! Whatever. DOUxx is just as good as DOWxx if that's the way you see the world. Just be consistant. As the "next" guy that's all I ask. } +--- | This is the Midrange System Mailing List! | To submit a new message, send your mail to MIDRANGE-L@midrange.com. | To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: david@midrange.com +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.