OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #include "stdio.h" | 8 #include "stdio.h" |
9 #include "SkSLParser.h" | 9 #include "SkSLParser.h" |
10 #include "SkSLToken.h" | 10 #include "SkSLToken.h" |
11 | 11 |
12 #define register | 12 #define register |
13 #ifdef __clang__ | 13 #ifdef __clang__ |
14 #pragma clang diagnostic push | 14 #pragma clang diagnostic push |
15 #pragma clang diagnostic ignored "-Wunneeded-internal-declaration" | 15 #pragma clang diagnostic ignored "-Wunneeded-internal-declaration" |
| 16 #pragma clang diagnostic ignored "-Wnull-conversion" |
16 #endif | 17 #endif |
17 #include "lex.sksl.c" | 18 #include "lex.sksl.c" |
18 #ifdef __clang__ | 19 #ifdef __clang__ |
19 #pragma clang diagnostic pop | 20 #pragma clang diagnostic pop |
20 #endif | 21 #endif |
21 #undef register | 22 #undef register |
22 | 23 |
23 #include "ast/SkSLASTBinaryExpression.h" | 24 #include "ast/SkSLASTBinaryExpression.h" |
24 #include "ast/SkSLASTBlock.h" | 25 #include "ast/SkSLASTBlock.h" |
25 #include "ast/SkSLASTBoolLiteral.h" | 26 #include "ast/SkSLASTBoolLiteral.h" |
(...skipping 1355 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1381 bool Parser::identifier(std::string* dest) { | 1382 bool Parser::identifier(std::string* dest) { |
1382 Token t; | 1383 Token t; |
1383 if (this->expect(Token::IDENTIFIER, "identifier", &t)) { | 1384 if (this->expect(Token::IDENTIFIER, "identifier", &t)) { |
1384 *dest = t.fText; | 1385 *dest = t.fText; |
1385 return true; | 1386 return true; |
1386 } | 1387 } |
1387 return false; | 1388 return false; |
1388 } | 1389 } |
1389 | 1390 |
1390 } // namespace | 1391 } // namespace |
OLD | NEW |