On Unix and Unix-like systems (such as macOS and Linux), beginning a script with #! followed by a path to an interpreter and arguments tells the system to use that interpreter to run the script - that's why, as an example, many python programs start with the line #!/usr/bin/env python.
The simplest way to implement this is to allow comments to start with # in addition to //.
I was able to get this working with only minor additions to src/lexer.rs - pull request will follow shortly.
On Unix and Unix-like systems (such as macOS and Linux), beginning a script with
#!followed by a path to an interpreter and arguments tells the system to use that interpreter to run the script - that's why, as an example, many python programs start with the line#!/usr/bin/env python.The simplest way to implement this is to allow comments to start with
#in addition to//.I was able to get this working with only minor additions to
src/lexer.rs- pull request will follow shortly.