Re: Compiling continuation characters
Re: Compiling continuation characters
- Subject: Re: Compiling continuation characters
- From: Christopher Nebel <email@hidden>
- Date: Mon, 9 Jun 2008 14:27:20 -0700
On Jun 6, 2008, at 8:12 AM, Ed Stockly wrote:
This one is for an appleScript Chris...
There's been a glitch in the AppleScript compiler that's kind of
irsome.
When using the continuation character with variables in a command,
everything looks fine...
set resultValue to choose from list directParamValue ¬
with title variable ¬
with prompt withPromptText ¬
default items defaultItemsValue ¬
OK button name OKButtonNameText ¬
cancel button name cancelButtonNameText ¬
multiple selections allowed multipleSelectionsAllowedBoolean ¬
empty selection allowed emptySelectionAllowedBoolean
But, take the same command and replace variables with text and it
shifts the command parameters around resulting in this:
set resultValue to choose from list directParamValue ¬
with title ¬
"text" with prompt withPromptText ¬
default items defaultItemsValue ¬
OK button name ¬
"More Text" cancel button name cancelButtonNameText ¬
multiple selections allowed multipleSelectionsAllowedBoolean ¬
empty selection allowed emptySelectionAllowedBoolean
There are other ways continuation characters don't retain their
positions on compile.
Can that be fixed?
Maybe. It's interesting that variable vs. literal makes a difference;
that particular case might be fixed if you file a bug. Fixing the
general case would require a fundamentally different approach to how
source text is handled.
--Chris Nebel
AppleScript Engineering
_______________________________________________
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