MACSCRPT Archives

May 2003

MACSCRPT@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Walter Ian Kaye <[log in to unmask]>
Reply To:
Macintosh Scripting Systems <[log in to unmask]>
Date:
Sat, 17 May 2003 17:01:22 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (39 lines)
At 03:20p +0100 05/17/2003, Nigel Garvey didst inscribe upon an
electronic papyrus:

>Walter Ian Kaye wrote on Fri, 16 May 2003 14:12:27 -0700:
>
>>Is unexpected behavior of an unsupported coercion considered a bug?
>>I guess nobody's tried '1.5 as integer' lately.
>
>It's the double integer itself that's not supported in AppleScript,
>otherwise a coercion to it would have to be supported to make it
>usable. The only number types mentioned in ASLG are integer and
>real. Anything else is for the language's internal use or for future
>expansion, not something that scripters are supposed to see or use.

Oh I don't know about that. It could also be argued that any type
which decompiles to a corresponding English term is indeed something
that scripters may use. Of course any term is subject to change, as
we saw in the transition from System 7 to 8 where the code for file
types got "(obsolete)" tacked on; such changes are not limited to
"internal use" codes.

>>The double integer is not a real, it is a double integer. Remember
>>that AppleScript often rounds terms off (e.g., text -> string), so
>>just because it tells you that a double integer is a real does not
>>make it so.
>
>Sorry. I don't understand this.

I mean, when Script Editor tells you. At least Script Debugger
provides a facility for looking "behind" an apparent data type, which
came in extremely handy when I was trying to script GraphicConverter
and it insisted on unstyled text; if one had been using SE, or if one
did not know that in AS a string is not just a string, one would have
given up in utter frustration. (NB: I wrote to the developer of GC
and asked that the text coercions be handled internally to save
scripters some grief.)

-boo

ATOM RSS1 RSS2