Scripting languages and IDEs (was: If python goes EToys...)

Marcel Weiher marcel at metaobject.com
Thu Aug 24 18:57:24 UTC 2006


Interesting discussion, as I have been wrestling with this very issue  
in my Objective-Smalltalk / stsh work for some time now.

On Aug 24, 2006, at 14:13 , Oscar Nierstrasz wrote:


> MyClass defineMethod: #mymethod withBody: [ ^ self ]

This is close to what I currently have, but it's not really very pretty.

> It seems like some new syntax would be needed if you want readable  
> and editable scripts.

While I agree, I do find that in practical use of stsh, my scripts  
tend to generally not need new method definitions very much.   
Scripting does seem to be somewhat different from (other) OO  
programming, though I do also think that the transition should be a  
smooth one, so it should be easy and elegant to define methods and  
classes.  At least that's one of my motivations for having something  
like (Objective-)Smalltalk as a scripting language:  there should be  
no breaks as a script evolves into something larger.

And maybe if it were easier I would do more of it in my scripts!


>
> Maybe some kind of bang-notation to separate method declarations  
> from executable code is not so bad!
>
> !MyClass>>mymethod
> 	^ self !

That is machine readable, not human read-/writable, IMHO.

One idea that's been on my mind for a bit is that maybe for an OO  
scripting system, classes should be defined in separate script files?   
So the script file itself can define a sort of implicit class context,  
but this can vary.  Hmm..

Marcel




More information about the Squeak-dev mailing list