esseks / monicelli

An esoteric programming language, come se fosse antani.
GNU General Public License v3.0
1.32k stars 52 forks source link

Compiler should output and read to/from file #15

Closed esseks closed 8 years ago

esseks commented 9 years ago

Current behaviour is reading from stdin and writing to stdout. We should allow file I/O.

I propose the following behaviour:

  1. If a filename is specified, e.g. example.mc, read from it and emit example.cpp (replacing the mc suffix with cpp).
  2. A different name for the output file might be specified by supplying a second argument.
  3. Specifying - as first or second argument connects the input/output to stdin/stdout.
  4. Not specifying any argument means read from stdin and write to stdout.
melfnt commented 9 years ago

Just a comment: mc is a suffix in your example, not a prefix

esseks commented 9 years ago

You are right and I should totally proofread what I write :)

esseks commented 8 years ago

Closing as this issue was solved in 22f4c33