Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1266)

Side by Side Diff: pkg/analyzer/lib/src/generated/testing/ast_factory.dart

Issue 489173002: New analyzer snapshot. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // This code was auto-generated, is not intended to be edited, and is subject to 5 // This code was auto-generated, is not intended to be edited, and is subject to
6 // significant change. Please see the README file for more information. 6 // significant change. Please see the README file for more information.
7 7
8 library engine.testing.ast_factory; 8 library engine.testing.ast_factory;
9 9
10 import 'package:analyzer/src/generated/utilities_dart.dart'; 10 import 'package:analyzer/src/generated/utilities_dart.dart';
(...skipping 28 matching lines...) Expand all
39 static AssertStatement assertStatement(Expression condition) => new AssertStat ement(TokenFactory.tokenFromKeyword(Keyword.ASSERT), TokenFactory.tokenFromType( TokenType.OPEN_PAREN), condition, TokenFactory.tokenFromType(TokenType.CLOSE_PAR EN), TokenFactory.tokenFromType(TokenType.SEMICOLON)); 39 static AssertStatement assertStatement(Expression condition) => new AssertStat ement(TokenFactory.tokenFromKeyword(Keyword.ASSERT), TokenFactory.tokenFromType( TokenType.OPEN_PAREN), condition, TokenFactory.tokenFromType(TokenType.CLOSE_PAR EN), TokenFactory.tokenFromType(TokenType.SEMICOLON));
40 40
41 static AssignmentExpression assignmentExpression(Expression leftHandSide, Toke nType operator, Expression rightHandSide) => new AssignmentExpression(leftHandSi de, TokenFactory.tokenFromType(operator), rightHandSide); 41 static AssignmentExpression assignmentExpression(Expression leftHandSide, Toke nType operator, Expression rightHandSide) => new AssignmentExpression(leftHandSi de, TokenFactory.tokenFromType(operator), rightHandSide);
42 42
43 static BlockFunctionBody asyncBlockFunctionBody(List<Statement> statements) => new BlockFunctionBody(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "async"), null, block(statements)); 43 static BlockFunctionBody asyncBlockFunctionBody(List<Statement> statements) => new BlockFunctionBody(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "async"), null, block(statements));
44 44
45 static ExpressionFunctionBody asyncExpressionFunctionBody(Expression expressio n) => new ExpressionFunctionBody(TokenFactory.tokenFromTypeAndString(TokenType.I DENTIFIER, "async"), TokenFactory.tokenFromType(TokenType.FUNCTION), expression, TokenFactory.tokenFromType(TokenType.SEMICOLON)); 45 static ExpressionFunctionBody asyncExpressionFunctionBody(Expression expressio n) => new ExpressionFunctionBody(TokenFactory.tokenFromTypeAndString(TokenType.I DENTIFIER, "async"), TokenFactory.tokenFromType(TokenType.FUNCTION), expression, TokenFactory.tokenFromType(TokenType.SEMICOLON));
46 46
47 static BlockFunctionBody asyncGeneratorBlockFunctionBody(List<Statement> state ments) => new BlockFunctionBody(TokenFactory.tokenFromTypeAndString(TokenType.ID ENTIFIER, "async"), TokenFactory.tokenFromType(TokenType.STAR), block(statements )); 47 static BlockFunctionBody asyncGeneratorBlockFunctionBody(List<Statement> state ments) => new BlockFunctionBody(TokenFactory.tokenFromTypeAndString(TokenType.ID ENTIFIER, "async"), TokenFactory.tokenFromType(TokenType.STAR), block(statements ));
48 48
49 static AwaitExpression awaitExpression(Expression expression) => new AwaitExpr ession(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "await"), expre ssion, TokenFactory.tokenFromType(TokenType.SEMICOLON)); 49 static AwaitExpression awaitExpression(Expression expression) => new AwaitExpr ession(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "await"), expre ssion);
50 50
51 static BinaryExpression binaryExpression(Expression leftOperand, TokenType ope rator, Expression rightOperand) => new BinaryExpression(leftOperand, TokenFactor y.tokenFromType(operator), rightOperand); 51 static BinaryExpression binaryExpression(Expression leftOperand, TokenType ope rator, Expression rightOperand) => new BinaryExpression(leftOperand, TokenFactor y.tokenFromType(operator), rightOperand);
52 52
53 static Block block(List<Statement> statements) => new Block(TokenFactory.token FromType(TokenType.OPEN_CURLY_BRACKET), list(statements), TokenFactory.tokenFrom Type(TokenType.CLOSE_CURLY_BRACKET)); 53 static Block block(List<Statement> statements) => new Block(TokenFactory.token FromType(TokenType.OPEN_CURLY_BRACKET), list(statements), TokenFactory.tokenFrom Type(TokenType.CLOSE_CURLY_BRACKET));
54 54
55 static BlockFunctionBody blockFunctionBody(Block block) => new BlockFunctionBo dy(null, null, block); 55 static BlockFunctionBody blockFunctionBody(Block block) => new BlockFunctionBo dy(null, null, block);
56 56
57 static BlockFunctionBody blockFunctionBody2(List<Statement> statements) => new BlockFunctionBody(null, null, block(statements)); 57 static BlockFunctionBody blockFunctionBody2(List<Statement> statements) => new BlockFunctionBody(null, null, block(statements));
58 58
59 static BooleanLiteral booleanLiteral(bool value) => new BooleanLiteral(value ? TokenFactory.tokenFromKeyword(Keyword.TRUE) : TokenFactory.tokenFromKeyword(Key word.FALSE), value); 59 static BooleanLiteral booleanLiteral(bool value) => new BooleanLiteral(value ? TokenFactory.tokenFromKeyword(Keyword.TRUE) : TokenFactory.tokenFromKeyword(Key word.FALSE), value);
(...skipping 386 matching lines...) Expand 10 before | Expand all | Expand 10 after
446 static VariableDeclarationStatement variableDeclarationStatement2(Keyword keyw ord, List<VariableDeclaration> variables) => variableDeclarationStatement(keywor d, null, variables); 446 static VariableDeclarationStatement variableDeclarationStatement2(Keyword keyw ord, List<VariableDeclaration> variables) => variableDeclarationStatement(keywor d, null, variables);
447 447
448 static WhileStatement whileStatement(Expression condition, Statement body) => new WhileStatement(TokenFactory.tokenFromKeyword(Keyword.WHILE), TokenFactory.to kenFromType(TokenType.OPEN_PAREN), condition, TokenFactory.tokenFromType(TokenTy pe.CLOSE_PAREN), body); 448 static WhileStatement whileStatement(Expression condition, Statement body) => new WhileStatement(TokenFactory.tokenFromKeyword(Keyword.WHILE), TokenFactory.to kenFromType(TokenType.OPEN_PAREN), condition, TokenFactory.tokenFromType(TokenTy pe.CLOSE_PAREN), body);
449 449
450 static WithClause withClause(List<TypeName> types) => new WithClause(TokenFact ory.tokenFromKeyword(Keyword.WITH), list(types)); 450 static WithClause withClause(List<TypeName> types) => new WithClause(TokenFact ory.tokenFromKeyword(Keyword.WITH), list(types));
451 451
452 static YieldStatement yieldEachStatement(Expression expression) => new YieldSt atement(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "yield"), Toke nFactory.tokenFromType(TokenType.STAR), expression, TokenFactory.tokenFromType(T okenType.SEMICOLON)); 452 static YieldStatement yieldEachStatement(Expression expression) => new YieldSt atement(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "yield"), Toke nFactory.tokenFromType(TokenType.STAR), expression, TokenFactory.tokenFromType(T okenType.SEMICOLON));
453 453
454 static YieldStatement yieldStatement(Expression expression) => new YieldStatem ent(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "yield"), null, ex pression, TokenFactory.tokenFromType(TokenType.SEMICOLON)); 454 static YieldStatement yieldStatement(Expression expression) => new YieldStatem ent(TokenFactory.tokenFromTypeAndString(TokenType.IDENTIFIER, "yield"), null, ex pression, TokenFactory.tokenFromType(TokenType.SEMICOLON));
455 } 455 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/generated/resolver.dart ('k') | pkg/analyzer/lib/src/generated/testing/element_factory.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698