Hey Mark,
Why is it that a method that is using the given clause doesn’t get recognized to be colorized in the same way as a method with round brackets?
I’m I missing something?
Hey Mark,
Why is it that a method that is using the given clause doesn’t get recognized to be colorized in the same way as a method with round brackets?
I’m I missing something?
You’re not missing anything – it’s simply not designed to work with handlers that use labelled syntax.
this is an Applscript compiler issue, not an Script Debugger problem, right?
I took it to be a reference to Script Debugger’s Apply color to method and handler names
feature.
Got it, thanks! That explains it.
Can it be solved in the next version then?
It can certainly be added to the wish-list.
I must say, I didn’t think many people bothered with that form of labelled syntax any more…
Hey Shane,
It makes your code so readable…
How do you do it then? with round brackets?
or you can use it the following way:
doMethod({theID:mID, theName:mName})
on doMethod(par)
set mID to par’s theID
set mName to par’s theName
– do something with it
end
For readability, I prefer interleaved terminology:
my doMethodID:mID andName:mName
on doMethodID:theID andName:theName
...