- Akhil Macherla (2019A7PS1211H)
- Aryan Arora (2019A7PS1204H)
- Sidharth Anand (2019A7PS1203H)
- Yashaswi Yenugu (2019A7PS1210H)
======================================================================
Parse a YeetScript file and output the token list
USAGE
$ YeetScriptCompiler parse [FILE] [-n] [-w]
ARGUMENTS
FILE Path to the YeetScript file to parse
FLAGS
-n, --include-newlines
-w, --include-whitespaces
DESCRIPTION
Parse a YeetScript file and output the token list
EXAMPLES
$ YeetScriptCompiler parse main.ys
See code: src/commands/parse.ts
Display help for YeetScriptCompiler.
USAGE
$ YeetScriptCompiler help [COMMAND] [-n]
ARGUMENTS
COMMAND Command to show help for.
FLAGS
-n, --nested-commands Include all nested commands in the output.
DESCRIPTION
Display help for YeetScriptCompiler.
See code: @oclif/plugin-help
To get YeetScriptCompiler up and running you must have nodejs and yarn installed.
- Clone the repo (
git clone https://github.com/sidharth-anand/YeetScript.git
) - Move into the project (
cd YeetScript
) - Install dependencies (
yarn install
) - Build the project (
yarn build
) - Run the parser with a test file (
./bin/dev parse test/sources/combined.ys
)
You can find JSDoc style documentation for every major class and function alongside the code.
All the files related to the language definition can be found in src/definitions
The transition rules for the DFA are at ys.rules and the BNF for YeetScript is at ys.bnf
DFA.png for the original high-res image
To test the project you can simply run
yarn test
This should trigger 11 extensive unit tests which cover all aspects of the YeetScript language and various codestyles. It should also contain failing tests for inavlid token sequences.
The examples are part of the test suite and conver all essential aspects of the YeetScript language. You can find them in test/sources.
The correct output token stream for these example YeetScript files can be found in test/tokens.