Simplify Web Application Development
Introducing Star Script (1): Accept Arbitrary Input
November 2, 2011Posted by on
Star Script is a fully featured, object-oriented programming language with templating langauge extensions. It is the world’s first dot star programming language. It can process arbitrary input program in a best effort manner and then execute it. Unlike any existing programming langauge compilers, Star Script compiler does not reject any input program with compilation errors.
Wait. Isn’t compiler suppose to catch as many errors as possible so the user don’t get into problems later? That is very common thinking. But that is not good enough. Simply detecting error and rejecting the input is not very user-friendly. Imagine living in a world that requires everything to be 100% correct. When you try to turn on your car, you get “Errors! CD player not responding. Small crack detected on your windshield. Please fix them and try turning on the car again”. How would you feel? I would be really annoyed. Engine, transmission, everything else is working. Please let me turn on the car. I will fix the problems later.
Star Script compiler detects all the syntax and semantic errors. If there is any error, instead of simply rejecting the input and refuse to run. Star Script compiler goes a step further, it tries to recover from those errors. Error will still be reported to the end-user if they want, but the program won’t refuse to run. When you get a true engine failure kind of error, Star Script program will still run, just with empty output.
Star Script intends to be a programming langauge that casual programmers can use. Casual means you don’t need to learn much to get started. If you leave it for a while and want to pick it up later, it shouldn’t take much effort. To meet this goal, taking arbitrary input is an absolute requirement. This is because, without any training, people can only produce arbitrary input. Thus, arbitrary input is what Star Script has to accept.