AndreVanDelft / scala

The SubScript extension to the Scala programming language
http://www.subscript-lang.org/
12 stars 1 forks source link

Start scripts using "script" rather than "def script" #48

Open AndreVanDelft opened 10 years ago

AndreVanDelft commented 10 years ago

For now a script or scripts section starts with "def script" whereas "script" would be much nicer. The reason is that "script" is still an identifier, rather than a keyword, and it would be quite hard (if I am right) to see in Scala expressions etc that this special identifiers starts a new script definition. A solution would be to ensure that "script" is scanned as a keyword. However this should be done conditionally, i.e. after "import subscript.language" or something like that.