Fun playing with jison.
The purpose of this "language" is to implement JavaScript SIMD into some unnecessary syntax and to learn jison. And also for fun.
Or probably, make my own Haskell! (nope, this is really bad joke)
-
Basic learning of CoffeeScript parser
-
Make proof-of-concept compiler
-
Basic binary
-
File loader
-
Implement basic syntax from 'Proposed syntax'
-
Scope system
-
Type system
-
REPL
-
Loops & if's
-
Error system
-
Add ramda as stdlib
-
Refactor and write some coffeescript's parts
-
Implement basic algorithms and structures in this lang
-
Conquer the world
Comments
-- inline comment
{- block comment -}
Types
-- both are Number type
integer = 1
float = 1.0
bool = True
string = "omg i'm a string"
-- Lists
list = [1, 2, 3, 4]
simdList = &[1, 2, 3, 4] {- SIMD-powered lists (do i need it in special syntax?) -}
-- Tuple
tuple = (1, 2, 3, 4)
-- Record
record = {True, 1}
Functions
double x = 2 * x
-- how about pattern matching?
double 1 = 2
double 2 = 4
Tests are in test
folder. Run npm test
for god's sake!
See docs
folder for more info on syntax and internals. Also dig into docs/coffeescript_nodes
for diagram of CoffeeScript nodes (AST of this language is based on CS).
Some parts of «language» is based on coffeescript code (really, not bad refference).
Arseniy Maximov, 2017 ©
(and CoffeeScript contributors)