Re: Default or optional arguments to handlers
Re: Default or optional arguments to handlers
- Subject: Re: Default or optional arguments to handlers
- From: Andy Wylie <email@hidden>
- Date: Tue, 23 Apr 2002 22:35:59 +1200
on 23/4/02 2:53 PM +1200: Timothy Bates wrote:
>
On 23/4/02 8:46 AM, "has" <email@hidden> wrote:
>
> I'm not sure overloading is as important to a loosely typed language like
>
> AS as to a strongly typed one. Optional parameters would be very nice,
>
> however.
>
>
My priority list is
>
1. all arrays are hashes, just like in php
>
set listA to {}
>
set "dog" of listA to ""fido"
>
get dog of listA
>
-->"fido"
>
get item 1 of listA
>
-->"fido"
>
>
> I wouldn't use lists myself: too much room for confusion. Also, I think the
>
> 'all-or-nothing' approach works best. I've tried using stuff like:
>
Absolutely: way confusing.
agreed OMM...
set listA to {dog:"fido"}
set ickyStuff to get ({listA}'s item 1 as string)
set AppleScript's text item delimiters to {""}
set thisDog to ickyStuff's text item -1
set AppleScript's text item delimiters to ""
thisDog
-- "fido"
_____________________________ Andy
http://www.sanyohk.com/kitty.htm
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.