[Newcompiler] Saphir scripting language for squeak
Mathieu Suen
mathieusuen at yahoo.fr
Sat Oct 28 23:06:13 UTC 2006
Hi,
You can try my new scripting language called Saphir at:
http://www.squeaksource.com/Saphir.html
Here the syntaxe:
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
More information about the Newcompiler
mailing list