Christopher Wright wrote:
Okay, here's an improved version of rdmd with config files.

Thanks, that's interesting.

Added features:
- Config file
  - Specify a compiler
  - Specify default imports for --eval
  - Specify build flags

I'm sorry, I think a config file is overkill. Perl has many more options and does fine without any configuration besides the envvar PERL5LIB.

But indeed there must be a possibility to veer away from the hardcoded imports.

- Option to show source with --eval

Sounds good.

- Changed the definition of "main" with --eval to use 'in char[][]' rather than 'string[]' (the args probably don't matter much anyway)

in char[][] is the worst of the pack because it's the supertype of both immutable and mutable. You're better off with either string[] or char[][].

- Executables are stored in the temp directory, not the current directory. This way, they can be reused even if you change directories; and they don't clutter up your working directory.

That's a good idea.

Attached is a sample rdmd.conf as well as the modified source (based on r958 from the phobos repository).

Thanks. Let's hold off on that for a bit until we all have the same phobos.


Andrei

Reply via email to