Battledash-2 / Neon

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸ”† Neon Lang 🟑

V2.1.2

What is Neon? (β„Ή)

Neon is a public and open source language (under the MIT license Β©).

πŸ“© Installation πŸ“‰

To install Neon:

  1. First, run git clone https://github.com/Battledash-2/Neon to clone the source code
  2. Second, create a Javascript file named run.js
  3. In the file, require the lexer, parser and interpreter in /src.
  4. To initiate, use new Interpreter().eval(new Parser(new Lexer('ANY CODE HERE')));

Alternatively:

  1. Clone the source code (like shown above)
  2. Run node . <MODE: [-f: File, -c: Console, Default: -c]> <MODE==FILE?FNAME: [-t: Show Exec Time]>

πŸ“ƒ Todo πŸ’Ή

  • Proxies (like the Javascript new Proxy(<OBJECT>, <PROXY>)) and the Lua setmetatable(<OBJECT>, <PROXY>))
  • ObjectPrototype.defineProperty (<OBJECT>.defineProperty(<NAME>, <FAKE-ISH PROXY: VALUE>))

🏁 Finished πŸ”š

  • OOP support (still missing extends keyword) (Classes)
  • (...initial) (objects, array, negated sets, if statements, for/while, variables, scopes)

😎 Examples πŸ§ͺ

  • Number interpreter with a lexer and parser (./examples/NumberInterpreter)
  • Mini-language / small lexer & parser-less language (./examples/MiniLang)
  • Lambda functions (./examples/LambdaFunctions)

About

License:MIT License


Languages

Language:JavaScript 100.0%