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

Side by Side Diff: pkg/analyzer/lib/src/kernel/ast_from_analyzer.dart

Issue 2828253003: Add top level type inference logic for integer literals. (Closed)
Patch Set: Clean up, bug fix, and remove unintentional expectations changes Created 3 years, 8 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 library kernel.analyzer.ast_from_analyzer; 4 library kernel.analyzer.ast_from_analyzer;
5 5
6 import 'package:kernel/ast.dart' as ast; 6 import 'package:kernel/ast.dart' as ast;
7 import 'package:kernel/frontend/super_initializers.dart'; 7 import 'package:kernel/frontend/super_initializers.dart';
8 import 'package:kernel/log.dart'; 8 import 'package:kernel/log.dart';
9 import 'package:kernel/type_algebra.dart'; 9 import 'package:kernel/type_algebra.dart';
10 import 'package:kernel/transformations/flags.dart'; 10 import 'package:kernel/transformations/flags.dart';
11 import 'package:analyzer/dart/ast/token.dart'; 11 import 'package:analyzer/dart/ast/token.dart';
12 import 'package:analyzer/dart/element/element.dart'; 12 import 'package:analyzer/dart/element/element.dart';
13 import 'package:analyzer/dart/element/type.dart'; 13 import 'package:analyzer/dart/element/type.dart';
14 import 'package:analyzer/src/kernel/loader.dart'; 14 import 'package:analyzer/src/kernel/loader.dart';
15 import 'package:analyzer/analyzer.dart'; 15 import 'package:analyzer/analyzer.dart';
16 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; 16 import 'package:analyzer/dart/ast/standard_resolution_map.dart';
17 import 'package:analyzer/src/generated/parser.dart'; 17 import 'package:analyzer/src/generated/parser.dart';
18 import 'package:analyzer/src/dart/element/member.dart'; 18 import 'package:analyzer/src/dart/element/member.dart';
19 import 'package:analyzer/src/error/codes.dart'; 19 import 'package:analyzer/src/error/codes.dart';
20 import 'package:front_end/src/fasta/kernel/frontend_accessors.dart'; 20 import 'package:kernel/frontend/accessors.dart';
21 21
22 /// Provides reference-level access to libraries, classes, and members. 22 /// Provides reference-level access to libraries, classes, and members.
23 /// 23 ///
24 /// "Reference level" objects are incomplete nodes that have no children but 24 /// "Reference level" objects are incomplete nodes that have no children but
25 /// can be used for linking until the loader promotes the node to a higher 25 /// can be used for linking until the loader promotes the node to a higher
26 /// loading level. 26 /// loading level.
27 /// 27 ///
28 /// The [ReferenceScope] is the most restrictive scope in a hierarchy of scopes 28 /// The [ReferenceScope] is the most restrictive scope in a hierarchy of scopes
29 /// that provide increasing amounts of contextual information. [TypeScope] is 29 /// that provide increasing amounts of contextual information. [TypeScope] is
30 /// used when type parameters might be in scope, and [MemberScope] is used when 30 /// used when type parameters might be in scope, and [MemberScope] is used when
(...skipping 3056 matching lines...) Expand 10 before | Expand all | Expand 10 after
3087 if (list[i - 1].compareTo(item) == 0) { 3087 if (list[i - 1].compareTo(item) == 0) {
3088 ++deleted; 3088 ++deleted;
3089 } else if (deleted > 0) { 3089 } else if (deleted > 0) {
3090 list[i - deleted] = item; 3090 list[i - deleted] = item;
3091 } 3091 }
3092 } 3092 }
3093 if (deleted > 0) { 3093 if (deleted > 0) {
3094 list.length -= deleted; 3094 list.length -= deleted;
3095 } 3095 }
3096 } 3096 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698