summaryrefslogtreecommitdiffstats
path: root/src/solar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/solar.cpp')
-rw-r--r--src/solar.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/solar.cpp b/src/solar.cpp
index 8d876d0..f3b04f6 100644
--- a/src/solar.cpp
+++ b/src/solar.cpp
@@ -78,8 +78,8 @@ bool read_grammar(const char *filename, parser_state_t *state) {
int main(int argc, char *argv[]) {
using namespace solar;
- if (argc < 2) {
- std::fprintf(stderr, "Usage: solar FILE\n");
+ if (argc < 4) {
+ std::fprintf(stderr, "Usage: solar INPUT SOURCE HEADER\n");
return 1;
}
@@ -89,7 +89,7 @@ int main(int argc, char *argv[]) {
generator_t generator(state.get_rules(), state.get_nonterm_types(), state.get_term_types());
- output_t output(&generator, "/dev/stdout", "/dev/stdout");
+ output_t output(&generator, argv[3], argv[2]);
output.write();
return 0;