• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to do a goto with Applescript?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to do a goto with Applescript?


  • Subject: Re: How to do a goto with Applescript?
  • From: Alex Zavatone <email@hidden>
  • Date: Tue, 11 Jan 2011 20:49:54 -0600


On Jan 11, 2011, at 2:21 PM, Stan Cleveland wrote:

On Jan 11, 2011, at 5:32 AM, Alex Zavatone wrote:

Why be sloppy writing a short script?  Your habits become patterns.  It is not wise to break good ones.

I agree, Alex. And as far as good programming habits go, for my own work I try to keep these two principles in mind:

"Any code of your own that you haven't looked at for six or more months might as well have been written by someone else." -- Eagleson's Law of Programming (anonymous)


EXACTLY.  And with descriptive variable and method names, your code becomes self descriptive and to some extent, self documenting.  I can look at the code I wrote 10 years ago and breeze through it because of this approach and of organizing into classes and declaring formal APIs.

"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." -- Brian W. Kernighan

And this approach makes code inherently easy to debug.  A 500 line handler with nested if statements and non descriptive variable names inherently isn't.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >Re: How to do a goto with Applescript? (From: Shane Stanley <email@hidden>)
 >Re: How to do a goto with Applescript? (From: Alex Zavatone <email@hidden>)
 >Re: How to do a goto with Applescript? (From: Stan Cleveland <email@hidden>)

  • Prev by Date: Re: How to do a goto with Applescript?
  • Next by Date: Re: How to do a goto with Applescript?
  • Previous by thread: Re: How to do a goto with Applescript?
  • Next by thread: Re: How to do a goto with Applescript?
  • Index(es):
    • Date
    • Thread