PleaseLangInterpreter

The file with the code to interpret the Please lang
Since:
  • 8/04/2021
Author:

Methods

inner interpret(program) → {*}

A function that interprets a Please AST
Parameters:
Name Type Description
program Object The AST of the program to interpret
Throws:
Will throw if there are syntactical errors
Returns:
* - The return value of the program

inner interpretFromFile(fileName) → {*}

A function that interprets a compiled Please file
Parameters:
Name Type Description
fileName string The name of the file
Throws:
Will throw if it isn't possible to read the file or if there are syntactical errors
Returns:
* - The return value of the program

inner run(program) → {*}

Parses and executes a Please program
Parameters:
Name Type Description
program Object The Please program to run
Throws:
Will throw if there are errors in the program
Returns:
* - The return value of the program

inner runFromFile(fileName) → {*}

A function that interprets a Please file
Parameters:
Name Type Description
fileName string The name of the file
Throws:
Will throw if it isn't possible to read the file or if there are errors in the program
Returns:
* - The return value of the program