Chunk order must be small to large

Ben Rubinstein benr at cogapp.com
Fri Mar 13 09:18:16 EDT 2009


Richard Gaskin wrote:
> I went to the mat with him over this one years ago when I was porting an 
> HC project.  He said, "If you need a custom behavior, use a custom 
> name."  I said, "But I *need* to override the built-in function!" and he 
> asked simply, "'Need'? Why?"  I couldn't think of a truly necessary case.

"Truly necessary" is never going to be a really objective measure, and hence 
is not an easy threshold to meet.  Especially talking to someone who could 
insist that there was no need for a constant equal to numtochar(13) because 
"real programmers wouldn't use it", and that a simple statement, legal in the 
syntax, which crashed Rev with 100% reliability shouldn't be marked "critical" 
because it could only affect the programmer, who should know better.  So I'm 
not suggesting any of the following would have got you off the mat.  However, 
here's a couple of cases:

* Relating to a recent discussion: I'd quite like my IDE extensions to 
override "answer" with a version that always had a special 'emergency exit' 
control, which would cause it to exit to top in the thread that invoked answer.

* RevBrowser responds to a javascript alert in the hosted page by invoking 
'answer'.  I'd really like to trap this - currently I can't see any way to do 
so.  If I could override "answer", I'd have a method.

...but really I'm playing devil's advocate: I'm very happy with the trade-offs 
Scott Raney made that give us blazing speed.

Ben




More information about the use-livecode mailing list