Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jsmolka/drizzle
A dynamic interpreted programming language.
https://github.com/jsmolka/drizzle
cpp drizzle dynamic interpreter language
Last synced: about 2 months ago
JSON representation
A dynamic interpreted programming language.
- Host: GitHub
- URL: https://github.com/jsmolka/drizzle
- Owner: jsmolka
- License: mit
- Created: 2021-08-05T14:58:58.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-11-23T16:53:13.000Z (about 2 years ago)
- Last Synced: 2023-03-10T04:17:25.169Z (almost 2 years ago)
- Topics: cpp, drizzle, dynamic, interpreter, language
- Language: C++
- Homepage: https://smolka.dev/drizzle
- Size: 959 KB
- Stars: 10
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# drizzle
A dynamic interpreted programming language.(it's not Python, I swear)
## Usage
```
usage:
drizzle [-h] [-a]keyword arguments:
-h, --help print help
-a, --ast print astpositional arguments:
file script file
```Additional arguments can be passed after `` and later be accessed through the `arguments` function.
## Examples
```python
class Point:
def init(x, y):
this.x = x
this.y = y
def cross(other):
return this.x * other.y - this.y * other.x# Stokes' theorem
def area(polygon):
var s = 0
for i in 0 .. len(polygon):
s = s + polygon[i - 1].cross(polygon[i])
return s / 2var triangle = [Point(0, 0), Point(4, 4), Point(0, 4)]
assert(area(triangle) == 8.0)
```See [examples](/examples) for more.
## Binaries
Binaries for Windows, Linux and macOS are available as [nightly](https://nightly.link/jsmolka/drizzle/workflows/build/master) and [release](https://github.com/jsmolka/drizzle/releases) builds.## Build
Detailed build instructions can be found [here](BUILD.md).## Credit
Thanks to Robert Nystrom for [Crafting Interpreters](https://www.craftinginterpreters.com).