summaryrefslogtreecommitdiffstats
path: root/src/parsers_test.cc
Commit message (Collapse)AuthorAgeFilesLines
* Rename parsers.* to manifest_parser.*Thiago Farina2012-07-091-684/+0
| | | | | | So it matches with the class name in there. Signed-off-by: Thiago Farina <tfarina@chromium.org>
* improve testScott Graham2012-06-151-8/+7
|
* add $in_newlineScott Graham2012-06-151-0/+18
|
* allow UTF-8 in rule descriptionsEvan Martin2012-04-261-0/+7
| | | | | The lexer already mostly allowed this, except that chars >127 were being interpreted as negative indexes into the lexer table.
* fix some public/private errors in rspfile patchEvan Martin2012-02-231-2/+2
|
* Response filesunknown2012-02-091-0/+18
|
* parse $:Peter Kuemmel2012-01-291-4/+33
| | | | | '$:' is a valid string now, it expands to ':' update error messages and show a hint when something went wrong.
* Lexer: include leading spaces in the newline token.Evan Jones2012-01-051-0/+28
| | | | This means that indented blank lines are skipped without causing errors.
* test error message of ManifestParser::LoadEvan Martin2012-01-051-2/+9
| | | | Fixes the other half of issue #187.
* make Lexer::Error not emit trailing newlineEvan Martin2012-01-051-18/+18
| | | | | Now it's consistent with other errors. Fixes part of issue #187.
* Lexer: include leading whitespace in the comment token.Evan Jones2012-01-051-7/+18
| | | | Indented comments are ignored rather than causing errors.
* Add a space to unexpected token errors.Evan Jones2012-01-041-0/+7
|
* switch the core ninja parser to use re2c for the lexerEvan Martin2011-12-291-71/+130
| | | | | | | | | - Delete the old "Tokenizer" code. - Write separate tests for the lexer distinct from the parser. - Switch the parser to use the new code. - New lexer error output has file:line numbers so e.g. Emacs can jump your editor to the syntax error. - The EvalEnv ($-interpolation) code is now part of the lexer as well.
* Follow up fix to commit 32bf74f (Fix the TODO in Rule class.)Thiago Farina2011-12-241-2/+2
| | | | Signed-off-by: Thiago Farina <tfarina@chromium.org>
* fix bad mergeEvan Martin2011-12-201-3/+3
|
* Merge pull request #146 from nornagon/escape-spacesEvan Martin2011-12-201-0/+13
|\ | | | | Escape spaces
| * Add tests for escaping spaces with '$ '.Jeremy Apthorp2011-11-281-0/+13
| |
* | split out depfile parser tests into new fileEvan Martin2011-12-191-34/+0
| |
* | remove makefile parsing code, use depfile code insteadEvan Martin2011-12-071-6/+7
| |
* | make Rule::name_ privateEvan Martin2011-12-071-2/+2
| |
* | make Node::in_edge_ privateEvan Martin2011-12-071-2/+2
| |
* | merge FileStat into NodeEvan Martin2011-12-071-3/+3
|/ | | | | | The two were always one-to-one anyway. I started adding accessors to FileStat and then realized most users wanted them on Node and that forwarding them through was silly.
* make CanonicalizePath report an error on empty pathEvan Martin2011-10-061-0/+20
| | | | Fixes part of issue 121, but the fix exposed a further issue.
* use StringPiece for makefile depsEvan Martin2011-09-121-2/+2
| | | | | | | | | | | | Because of this, MakefileParser now returns pointers into the source makefile string rather than allocating new strings. Despite needing to take the result and stuff it into a new string anyway to canonicalize it, this takes another 50ms or so off the null Chrome build, likely due to the vector used in MakefileParser changing to a type that doesn't use any allocations. (I also experimented with making the vector reserve an initial size but didn't see any performance impact.)
* Move a passing test from Errors to MultipleOutputsQingning Huo2011-09-061-10/+11
|
* Add depfile support to build command with multiple outputs (Fixes: #61)Qingning Huo2011-09-061-3/+2
| | | | | | | | | | | | | parsers.cpp: allow depfile used at build command with multiple outputs. graph.cpp: allow depfile used at build command with multiple outputs. parsers_test.cpp: make the test pass. As before, the depfile itself can only mention one target, which must be the first of a build command with multiple outpus. [There is really no need to mention all the output in the depfile, because all targets should depend on exactly the same files anyway, because these targets are built by a single build command.]
* Factor out State struct from ninja_jumble.cc into its header/source files.Thiago Farina2011-09-031-1/+1
| | | | | | This was a TODO in src/ninja_jumble.cc. Now this task is completed. Signed-off-by: Thiago Farina <tfarina@chromium.org>
* Implement default target statementsPeter Collingbourne2011-08-311-1/+64
| | | | | | This introduces a new directive, the default target statement, which may be used to control the list of targets built by default (i.e. if no target is named on the command line).
* expand $$ as $Evan Martin2011-05-271-0/+12
|
* switch to $ as the line continuation charEvan Martin2011-05-271-8/+8
| | | | | This means that backslashes are passed through without interpretation, allowing us to support Windows paths without worrying about escaping.
* add more test coverage for makefile parsingEvan Martin2011-05-251-0/+13
|
* refactor let parsing, passing another testEvan Martin2011-05-241-2/+1
|
* show correct location for unexpected var errorEvan Martin2011-05-231-2/+1
|
* refactor parser, check in some failing testsEvan Martin2011-05-231-0/+22
|
* include filename in subninja load err messageEvan Martin2011-05-221-1/+9
|
* windows: fix more signedness warningsEvan Martin2011-05-081-7/+7
|
* drop reserved words 'build'/'rule'/'subninja'/etc.Evan Martin2011-05-011-0/+7
| | | | | | | Instead, parse them as normal words, which makes them work as paths. We instead rely on the *position* (i.e., we start a statement with a keyword and not a path) to distinguish the keyword 'build' from the file 'build'.
* include location of error in parse error messages in EvalEnv stringsAlexei Svitkine2011-04-261-0/+24
| | | | | E.g. when parsing "foo = ${bar", point at the correct location of the missing curly brace.
* use util's CanonicalizePath in parsers as wellEvan Martin2011-04-221-0/+12
|
* add copyrightsEvan Martin2011-02-061-0/+14
|
* ignore whitespace in makefilesEvan Martin2011-02-041-0/+10
|
* refactor parse error messagesEvan Martin2011-02-041-1/+1
|
* allow implicit depsEvan Martin2011-01-231-1/+13
|
* add an include statementEvan Martin2011-01-151-0/+11
|
* split out graph into its own headerEvan Martin2011-01-081-0/+1
|
* aggressively eval variables in build blocksEvan Martin2010-12-211-2/+8
|
* immediately evaluate variables in top-level bindingsEvan Martin2010-12-211-1/+4
|
* allow one-letter variable namesEvan Martin2010-12-191-2/+4
|
* remove special builddirEvan Martin2010-12-191-31/+3
|
* expand variables in build pathsEvan Martin2010-12-191-0/+21
|