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

Side by Side Diff: pkg/compiler/lib/src/mirrors/dart2js_mirrors.dart

Issue 1880323002: dart2js cleanup: remove unused imports and variables (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: merge master Created 4 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
« no previous file with comments | « pkg/compiler/lib/src/library_loader.dart ('k') | pkg/compiler/lib/src/mirrors_used.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 library dart2js.mirrors; 5 library dart2js.mirrors;
6 6
7 import 'dart:collection' show UnmodifiableListView, UnmodifiableMapView; 7 import 'dart:collection' show UnmodifiableListView, UnmodifiableMapView;
8 8
9 import '../common.dart'; 9 import '../common.dart';
10 import '../compiler.dart' show Compiler; 10 import '../compiler.dart' show Compiler;
11 import '../constants/expressions.dart'; 11 import '../constants/expressions.dart';
12 import '../constants/values.dart'; 12 import '../constants/values.dart';
13 import '../dart_types.dart'; 13 import '../dart_types.dart';
14 import '../elements/elements.dart'; 14 import '../elements/elements.dart';
15 import '../elements/modelx.dart' show LibraryElementX; 15 import '../elements/modelx.dart' show LibraryElementX;
16 import '../resolution/scope.dart' show Scope; 16 import '../resolution/scope.dart' show Scope;
17 import '../script.dart'; 17 import '../script.dart';
18 import '../tokens/token.dart'; 18 import '../tokens/token.dart';
19 import '../tokens/token_constants.dart' as Tokens; 19 import '../tokens/token_constants.dart' as Tokens;
20 import '../tree/tree.dart'; 20 import '../tree/tree.dart';
21 import '../util/util.dart' show Link, LinkBuilder;
22 import '../util/characters.dart' show $CR, $LF; 21 import '../util/characters.dart' show $CR, $LF;
22 import '../util/util.dart' show Link;
23 import 'mirrors_util.dart';
24 import 'source_mirrors.dart';
23 25
24 import 'source_mirrors.dart'; 26 part 'dart2js_instance_mirrors.dart';
25 import 'mirrors_util.dart';
26
27 part 'dart2js_library_mirror.dart'; 27 part 'dart2js_library_mirror.dart';
28 part 'dart2js_member_mirrors.dart';
28 part 'dart2js_type_mirrors.dart'; 29 part 'dart2js_type_mirrors.dart';
29 part 'dart2js_member_mirrors.dart';
30 part 'dart2js_instance_mirrors.dart';
31 30
32 //------------------------------------------------------------------------------ 31 //------------------------------------------------------------------------------
33 // Utility types and functions for the dart2js mirror system 32 // Utility types and functions for the dart2js mirror system
34 //------------------------------------------------------------------------------ 33 //------------------------------------------------------------------------------
35 34
36 bool _includeLibrary(Dart2JsLibraryMirror mirror) { 35 bool _includeLibrary(Dart2JsLibraryMirror mirror) {
37 return const bool.fromEnvironment("list_all_libraries") || 36 return const bool.fromEnvironment("list_all_libraries") ||
38 !mirror._element.isInternalLibrary; 37 !mirror._element.isInternalLibrary;
39 } 38 }
40 39
(...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 if (!parameter.hasDefaultValue) return null; 471 if (!parameter.hasDefaultValue) return null;
473 ParameterElement parameterElement = parameter._element; 472 ParameterElement parameterElement = parameter._element;
474 Compiler compiler = parameter.mirrorSystem.compiler; 473 Compiler compiler = parameter.mirrorSystem.compiler;
475 return compiler.constants.getConstantForVariable(parameterElement); 474 return compiler.constants.getConstantForVariable(parameterElement);
476 } 475 }
477 476
478 static Mirror getMirrorFromElement(Dart2JsMirror mirror, Element element) { 477 static Mirror getMirrorFromElement(Dart2JsMirror mirror, Element element) {
479 return _convertElementToDeclarationMirror(mirror.mirrorSystem, element); 478 return _convertElementToDeclarationMirror(mirror.mirrorSystem, element);
480 } 479 }
481 } 480 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/library_loader.dart ('k') | pkg/compiler/lib/src/mirrors_used.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698