marbelous-lang / docs

Documentation, examples, etc.
Apache License 2.0
3 stars 3 forks source link

Board/program directives #5

Open m-ender opened 9 years ago

m-ender commented 9 years ago

es1024's implementation comes with a few options that seem useful, most notably

We can probably think of a few others...

I'm thinking, it doesn't really make sense for these things to be parameters of the interpreter. They should be tied to the code. A cylindrical board usually won't make sense if marbles are pushed off the edges instead and vice versa. So I'd say these belong into the code, and we can probably add them with directives similar to #include. And while we're at it, I was wondering if we couldn't actually make these per-board directives (and each board defaults to the main board's options).

mrskin commented 9 years ago

in perl, behavior like this is done with command line parameters, and those parameters are often present in the shebang line.

#!/usr/bin/env marbelous -p -c