escalier-lang / escalier

A compile-to-JavaScript language with tight TypeScript integration.
https://escalier-lang.github.io/escalier/
MIT License
21 stars 1 forks source link

Operator overloading #692

Open kevinbarabash opened 1 year ago

kevinbarabash commented 1 year ago

This is mainly to support linear algebra, e.g.

[1, 2, 3] + [3, 4, 5] -> [4, 6, 8]
a * [x, y, z] -> [a*x, a*y, a*z]

How would this work with matrices? What about differentiating row vectors vs column vectors?