diff options
author | Jeremy Apthorp <jeremya@chromium.org> | 2011-11-21 03:07:56 (GMT) |
---|---|---|
committer | Jeremy Apthorp <jeremya@chromium.org> | 2011-11-21 03:07:56 (GMT) |
commit | b363f6d8c456e24efb47b1b8d3c48f93c53ae5a4 (patch) | |
tree | 1b29c8b95739e427d3a073a106cf9ec27345cf8f /src/parsers.cc | |
parent | 73023f63f1539af51b3bbfc9d7233bc88bfe9b77 (diff) | |
download | Ninja-b363f6d8c456e24efb47b1b8d3c48f93c53ae5a4.zip Ninja-b363f6d8c456e24efb47b1b8d3c48f93c53ae5a4.tar.gz Ninja-b363f6d8c456e24efb47b1b8d3c48f93c53ae5a4.tar.bz2 |
Allow '$ ' to escape spaces in identifiers.
Diffstat (limited to 'src/parsers.cc')
-rw-r--r-- | src/parsers.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/parsers.cc b/src/parsers.cc index 4920496..97fa4a6 100644 --- a/src/parsers.cc +++ b/src/parsers.cc @@ -232,6 +232,9 @@ Token::Type Tokenizer::PeekToken() { if (IsIdentChar(*cur_)) { while (cur_ < end_ && IsIdentChar(*cur_)) { + if (*cur_ == '$' && cur_ + 1 < end_ && cur_[1] == ' ') { + ++cur_; + } ++cur_; } token_.end_ = cur_; |