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

Side by Side Diff: pkg/compiler/lib/src/ssa/kernel_ast_adapter.dart

Issue 2331923002: Handle signature types and fields in kernel_impact (Closed)
Patch Set: Updated cf. comments. Created 4 years, 3 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 4
5 import 'package:kernel/ast.dart' as ir; 5 import 'package:kernel/ast.dart' as ir;
6 6
7 import '../common.dart'; 7 import '../common.dart';
8 import '../compiler.dart'; 8 import '../compiler.dart';
9 import '../constants/values.dart'; 9 import '../constants/values.dart';
10 import '../dart_types.dart'; 10 import '../dart_types.dart';
(...skipping 17 matching lines...) Expand all
28 final Map<ir.Node, ast.Node> _nodeToAst; 28 final Map<ir.Node, ast.Node> _nodeToAst;
29 final Map<ir.Node, Element> _nodeToElement; 29 final Map<ir.Node, Element> _nodeToElement;
30 DartTypeConverter _typeConverter; 30 DartTypeConverter _typeConverter;
31 31
32 KernelAstAdapter( 32 KernelAstAdapter(
33 this._backend, 33 this._backend,
34 this._resolvedAst, 34 this._resolvedAst,
35 this._nodeToAst, 35 this._nodeToAst,
36 this._nodeToElement, 36 this._nodeToElement,
37 Map<FunctionElement, ir.Member> functions, 37 Map<FunctionElement, ir.Member> functions,
38 Map<FieldElement, ir.Field> fields,
38 Map<ClassElement, ir.Class> classes, 39 Map<ClassElement, ir.Class> classes,
39 Map<LibraryElement, ir.Library> libraries) { 40 Map<LibraryElement, ir.Library> libraries) {
40 for (FunctionElement functionElement in functions.keys) { 41 for (FunctionElement functionElement in functions.keys) {
41 _nodeToElement[functions[functionElement]] = functionElement; 42 _nodeToElement[functions[functionElement]] = functionElement;
42 } 43 }
44 for (FieldElement fieldElement in fields.keys) {
45 _nodeToElement[fields[fieldElement]] = fieldElement;
46 }
43 for (ClassElement classElement in classes.keys) { 47 for (ClassElement classElement in classes.keys) {
44 _nodeToElement[classes[classElement]] = classElement; 48 _nodeToElement[classes[classElement]] = classElement;
45 } 49 }
46 for (LibraryElement libraryElement in libraries.keys) { 50 for (LibraryElement libraryElement in libraries.keys) {
47 _nodeToElement[libraries[libraryElement]] = libraryElement; 51 _nodeToElement[libraries[libraryElement]] = libraryElement;
48 } 52 }
49 _typeConverter = new DartTypeConverter(this); 53 _typeConverter = new DartTypeConverter(this);
50 } 54 }
51 55
52 Compiler get _compiler => _backend.compiler; 56 Compiler get _compiler => _backend.compiler;
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 @override 164 @override
161 DartType visitDynamicType(ir.DynamicType node) { 165 DartType visitDynamicType(ir.DynamicType node) {
162 return const DynamicType(); 166 return const DynamicType();
163 } 167 }
164 168
165 @override 169 @override
166 DartType visitInvalidType(ir.InvalidType node) { 170 DartType visitInvalidType(ir.InvalidType node) {
167 throw new UnimplementedError("Invalid types not currently supported"); 171 throw new UnimplementedError("Invalid types not currently supported");
168 } 172 }
169 } 173 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/ssa/builder_kernel.dart ('k') | pkg/compiler/lib/src/ssa/kernel_impact.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698