loopily
v1.0.0
Published
Loopily programming language
Maintainers
Readme
Loopily
Loopily is a lightweight, QBasic-inspired scripting language built with Node.js. It is designed for learning how interpreters work while staying simple, readable, and extensible.
Features
- Variables using
LET - Output using
SAY - Conditional statements (
IF / ELSE) - Loops (
LOOP) - Functions (
FUN) - Function calls with parameters
- Basic arithmetic and comparison operators
- Runtime error reporting
Installation
Clone the repository:
Make sure Node.js is installed (recommended v16 or later).
Running Loopily
Run a .loop file:
loopily program.loopRun inline code:
loopily -e "SAY \"Hello Loopily\""Example Program
SAY "Hello Loopily"
LET name = "Ei Ei Htwe"
SAY name
LOOP 3
SAY "Loop running"
ENDLanguage Syntax
Variables
LET x = 10Output
SAY "Hello"
SAY xLoop
LOOP 5
SAY "Running"
ENDIf / Else
IF x > 5 THEN
SAY "Big number"
ELSE
SAY "Small number"
ENDFunctions
FUN greet name
SAY "Hello"
SAY name
END
greet "Loopily"Project Structure
loopily/
├── lexer.js
├── parser.js
├── evaluator.js
├── loopily.js
├── filecreate.js
├── package.json
├── program.loop
└── README.mdRoadmap
- Add real scope system (local variables)
- Add return values from functions
- Improve function call syntax
- Add REPL mode
- Add standard library functions
- Improve error recovery
- Publish as npm package
Notes
Loopily is a learning project focused on understanding:
- Parsing and tokenization
- Abstract Syntax Trees (AST)
- Interpreter design
- Execution flow and scope handling
It is not intended for production use at this stage.
License
MIT License
