- Paradigm: Procedural with prototypal inheritance.
- Syntax: Minimalist and simple for readability.
- Type System: Strong, static, with optional type inference.
- Memory Management: Garbage collected.
- Concurrency: Parallelism-focused for high performance.
- Function Definition and Call: Using
func
keyword for function definitions, with named arguments to allow any order of arguments during function calls. - Prototype Definition and Inheritance: Using
prototype
andextends
keywords for prototype definitions and inheritance respectively. - Method Call: Methods called on objects using the dot (
.
) operator. - Default Argument Values: Specified using equals sign (
=
) followed by the default value. - String Interpolation: Enabled with a dollar sign (
$
) prefix and curly braces ({}
) for variables and expressions.
- Fiber Definition and Control:
fiber
keyword to denote coroutines, withawait
for asynchronous operations andresume()
method to control execution.
- Importing and Exporting: Explicit imports and exports using
import
andexport
keywords respectively. Aliasing and selective importing for flexibility. - Module Resolution: File-based and folder-based modules with a system for path resolution and package management.
- Extensive but Modular: Providing a wide range of functionality while allowing users to only include what they need.
- Python-like Error Handling: Using a
try-catch
mechanism.
- Debugging and Profiling: Essential tools for debugging and profiling included.
- Build Systems: Multiple build systems for easy library management, possibly with a tool similar to
rustup
. - Package Management: A mechanism to easily download and manage third-party libraries.
- Transpilation: Allowing transpilation to other languages for broader usability.
- Standalone Executables: Targeting standalone executable deployment.
- Community-Driven: Fostering a community-driven ecosystem for library development and support.
- Implementation: The compiler will be implemented in JavaScript on Bun, with PEG.js.