[Newcompiler] Re: Saphir scripting language for squeak

Mathieu Suen mathieusuen at yahoo.fr
Sun Oct 29 07:22:43 UTC 2006


Stéphane Ducasse a écrit :
> math
> 
> some remarks:
>     - I guess that main is just the name of a method of the script. Is
> it the case because
>     else having main is more a pain ?

yes it's

> 
> We said that
> 
> foo [......]
> define a script method
> is it the case?

yes

> 
> so are run [] and declare [] script methods?

yes

> 
> Then what is the difference between run [...], declare [...] and foo [...]

There is no diffrence and run will be automaticly called

> 
> 
>> main [
>>    self haltIf: #run
>> ]
>>
>> declare [
>>     Object subclass: #Exemple
>>         instanceVariableNames: ''
>>         classVariableNames: ''
>>         poolDictionaries: ''
>>         category: 'SandBox'
>> ]
>>
>> Exemple instanceSideMethodExemple [
>>     ^4
>> ]
>>
>> Exemple class classSideMethodExemple [
>>     ^0
>> ]
>>
>> run [
>>     self declare.
>>     self main.
>>     Console printNl: 'End of script'
>> ]
>>
>>
>> To run your script put it in a file then open FileList and selected
>> your script.
>> You should see a "Do It" button. So click on it and this will execute
>> your script.
>>
>> Your script will be store in a subclass of ScriptInterpreter and have
>> the name of your file name.
>>
>> Now there is still plenty of works to do:
>>  -Right better tests
>>  -Add better declaration for class
>>  -Script class
>>  -Get sapphire working on the command line
>>  -Recover arguments from command line
>>
>> Enjoy and don't forget to give us feedback
>>
>> Thanks
>>     Math
>>
>>     
>>     
>>        
>> ___________________________________________________________________________
>>
>> Découvrez une nouvelle façon d'obtenir des réponses à toutes vos
>> questions !
>> Profitez des connaissances, des opinions et des expériences des
>> internautes sur Yahoo! Questions/Réponses
>> http://fr.answers.yahoo.com
>>
> 
> 


	

	
		
___________________________________________________________________________ 
Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! 
Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses 
http://fr.answers.yahoo.com


More information about the Newcompiler mailing list