Am 05.10.2005 um 22:27 schrieb Buzz Kettles:

Here's my 'true' dot syntax solution :
(using 'put' feels like cheating to me)


someString = someString.char[1..4] & "-" & someString.char [6..someString.char.count]

but it does something slightly different, in that it allocates a new string and deletes the old one, where the derivates of put alter the variable in memory (in place), which is MUCH FASTER especially, if you have to deal with long string variables.

personally I have no problem with using the syntax, which best fits my needs (I can't figure out, if I ever will replace "go the frame" with "_movie.go(_movie.frame)"), but still I think, that "put" wasn't dot-i-fied, as it is a "global function" and might very well be translated to something like:

"put ... into" -> insertChunk(str, chunk, fromPosition [, toPosition])
"put ... after"      -> appendChunk(str, chunk)
"put ... before"   -> prependChunk(str, chunk)

but, hey, "put" is short and straightforwarded and there 'still' are some very annoying bugs to fix, before wasting time on aesthetics...

---------------------------

  |||
a¿ex


[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email 
[email protected]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for 
learning and helping with programming Lingo.  Thanks!]

Reply via email to