OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef TOOLS_GN_PARSER_H_ | 5 #ifndef TOOLS_GN_PARSER_H_ |
6 #define TOOLS_GN_PARSER_H_ | 6 #define TOOLS_GN_PARSER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/basictypes.h" | |
12 #include "base/gtest_prod_util.h" | 11 #include "base/gtest_prod_util.h" |
| 12 #include "base/macros.h" |
13 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
14 #include "tools/gn/err.h" | 14 #include "tools/gn/err.h" |
15 #include "tools/gn/parse_tree.h" | 15 #include "tools/gn/parse_tree.h" |
16 | 16 |
17 class Parser; | 17 class Parser; |
18 typedef scoped_ptr<ParseNode> (Parser::*PrefixFunc)(Token token); | 18 typedef scoped_ptr<ParseNode> (Parser::*PrefixFunc)(Token token); |
19 typedef scoped_ptr<ParseNode> (Parser::*InfixFunc)(scoped_ptr<ParseNode> left, | 19 typedef scoped_ptr<ParseNode> (Parser::*InfixFunc)(scoped_ptr<ParseNode> left, |
20 Token token); | 20 Token token); |
21 | 21 |
22 extern const char kGrammar_Help[]; | 22 extern const char kGrammar_Help[]; |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 FRIEND_TEST_ALL_PREFIXES(Parser, Expression); | 123 FRIEND_TEST_ALL_PREFIXES(Parser, Expression); |
124 FRIEND_TEST_ALL_PREFIXES(Parser, FunctionCall); | 124 FRIEND_TEST_ALL_PREFIXES(Parser, FunctionCall); |
125 FRIEND_TEST_ALL_PREFIXES(Parser, List); | 125 FRIEND_TEST_ALL_PREFIXES(Parser, List); |
126 FRIEND_TEST_ALL_PREFIXES(Parser, ParenExpression); | 126 FRIEND_TEST_ALL_PREFIXES(Parser, ParenExpression); |
127 FRIEND_TEST_ALL_PREFIXES(Parser, UnaryOp); | 127 FRIEND_TEST_ALL_PREFIXES(Parser, UnaryOp); |
128 | 128 |
129 DISALLOW_COPY_AND_ASSIGN(Parser); | 129 DISALLOW_COPY_AND_ASSIGN(Parser); |
130 }; | 130 }; |
131 | 131 |
132 #endif // TOOLS_GN_PARSER_H_ | 132 #endif // TOOLS_GN_PARSER_H_ |
OLD | NEW |