Go to file
prod2 e83cd424f9 backtrack in parser + ampersand op support 2022-12-02 20:47:31 +01:00
benchmarks readding inline to some stack.nim procs 2022-02-14 10:46:49 +01:00
bin new test, bugfix 2022-02-05 03:24:30 +01:00
examples rename funct to proc 2022-02-09 06:58:51 +01:00
src backtrack in parser + ampersand op support 2022-12-02 20:47:31 +01:00
tests parser progress 2022-12-02 19:14:41 +01:00
.gitignore update gitignore 2022-12-02 12:10:51 +01:00
LICENSE Update LICENSE 2022-01-20 21:23:53 +00:00
README.md compiler rewrite start 2022-12-02 15:45:34 +01:00
nds.nimble Revert "BROKEN gc" 2022-02-14 07:15:11 +01:00
nim.cfg change project structure 2022-01-29 22:33:34 +01:00

README.md

nondescript

Nondescript is a toy programming language. Currently its compiler is being rewritten, so please check the latest commit from Feb 2022 to see a working version in action.

Some of nondescript's features

  • Almost everything is an expression
  • block expressions can be labelled (@label) and the break statement takes a label to break out of
  • set block expression results using :label
  • set the return value of functions using :result
  • lists (example: @[1, 4, 5])
  • tables (example: @{ "hello" = "world"})
  • length operator #
  • ampersand operator to chain binary operators to finished expressions
  • just a little syntax sugar (see sugar.nds in tests)
  • and some more (an introduction to nondescript coming soon...)

Examples

See the following folders in the source tree, look for the extension .nds:

  • benchmarks/
  • examples/
  • tests/

Building

Requirements:

  • nim (1.6.8 tested) and nimble (recommended way to install is choosenim)
  • c compiler (gcc tested)

The 4 steps to a REPL:

git clone https://github.com/prod2/nondescript
cd nondescript
nimble build
bin/nds