• 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: can I make a list of records?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: can I make a list of records?


  • Subject: Re: can I make a list of records?
  • From: Nigel Garvey <email@hidden>
  • Date: Wed, 30 Jan 2002 08:55:52 +0000

Paul Berkowitz wrote on Tue, 29 Jan 2002 08:47:48 -0800:

>On 1/29/02 8:25 AM, "Nigel Garvey" <email@hidden>
>wrote:
>
>> What you'd expect from a concatentation of three lists - but not if
>> MyList is actually an empty record. Maybe {} is interpreted as a list or
>> a record according to the circumstances.
>>
>> ?
>
>Yes. I think this came up about 6 months ago - maybe a year, in a slightly
>different aspect. Chris N. explained how this happened, but I'm afraid I've
>forgotten the details. I think empty {} brackets do begin life as empty
>records and get re-interpreted somewhere along the line.

Yes, I vaguely remember that. I've just looked it up. It was actually
Chris Espinosa, who wrote, back in May:

>When the Finder returns an empty value collective Get Data operation
>(anything with a plural anywhere in the direct object, such as your
>"name of folders of myFolder"), it doesn't return an empty list, it
>returns an empty *record*. Which looks and prints and smells like an
>empty list, and compares correctly to an empty list, but can't do
>list-like things, like having its end set. Your commented-out line is
>unfortunately the correct workaround, as there's no way to specify an
>empty record in AppleScript itself.

This is different from the current situation, where the {} has been
created in AppleScript itself and *can* have its end set, so behaves like
an empty list. However, if a record is concatenated to it, the result is
a record, not a list, giving the impression that the empty list is really
an empty record.

NG


  • Prev by Date: Re: Scripting Additions: Embracing the Horror of Unix
  • Next by Date: Launching by variable in OS X
  • Previous by thread: Re: can I make a list of records?
  • Next by thread: Break into a timeout loop
  • Index(es):
    • Date
    • Thread