diff options
| author | 2024-02-28 12:09:56 +0800 | |
|---|---|---|
| committer | 2024-02-28 12:09:56 +0800 | |
| commit | 8793ecea74706aedb4674434f65ef9d05850b769 (patch) | |
| tree | 425fcec75d4f899760a0919fa0604327b20309f9 /nivis-python/execution.py | |
| parent | ab026b7e0ba3baa1ffab7603e7f5fa47864427f7 (diff) | |
| download | TRPGNivis-8793ecea74706aedb4674434f65ef9d05850b769.tar.gz TRPGNivis-8793ecea74706aedb4674434f65ef9d05850b769.zip | |
refactor(bones)!: rename nivis-python -> nivis_python
Diffstat (limited to 'nivis-python/execution.py')
| -rw-r--r-- | nivis-python/execution.py | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/nivis-python/execution.py b/nivis-python/execution.py deleted file mode 100644 index 09055cf..0000000 --- a/nivis-python/execution.py +++ /dev/null @@ -1,47 +0,0 @@ -from .parsers import Parser -from .interpreter import Interpreter - -__all__ = ["Execution"] - - -class Execution: - """ - A class representing the execution of Psi code. - - Args: - input: The input code to be executed. - - Returns: - None - - Example: - ```python - execution = Execution("print('Hello, World!')") - execution.execute() - ``` - """ - - def __init__(self, input): - """ - Initializes an Execution object. - - Args: - input: The input code to be executed. - - Returns: - None - """ - self.input = input - - def execute(self): - """ - Executes the input code. - - Returns: - The result of the execution. - """ - parser = Parser(self.input) - ast = parser.parse() - - interpreter = Interpreter(ast) - return interpreter.interpret() |
