diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2015-09-09 15:56:54 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2015-09-09 15:56:54 +0200 |
commit | ea66709a853255c7957a8a7907fd21fa7f6cfd3f (patch) | |
tree | 061f828174b4a1d9d5c5fbc0b3b7427b5eea1ee8 /build/token.cxx | |
parent | 8a9870ed59225972de389b7b4a494a57390bff1b (diff) |
Add support for quoting directive names
Now only unquoted, literal names are recognized as directives, for
example:
'print' = abc
print $print
Diffstat (limited to 'build/token.cxx')
-rw-r--r-- | build/token.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/build/token.cxx b/build/token.cxx index 22f5b75..35a7f89 100644 --- a/build/token.cxx +++ b/build/token.cxx @@ -13,7 +13,7 @@ namespace build ostream& operator<< (ostream& os, const token& t) { - switch (t.type ()) + switch (t.type) { case token_type::eos: os << "<end-of-file>"; break; case token_type::newline: os << "<newline>"; break; @@ -26,7 +26,7 @@ namespace build case token_type::dollar: os << "$"; break; case token_type::lparen: os << "("; break; case token_type::rparen: os << ")"; break; - case token_type::name: os << t.name (); break; + case token_type::name: os << t.value; break; } return os; |