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

Side by Side Diff: pkg/compiler/lib/src/mirrors_used.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
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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_used; 5 library dart2js.mirrors_used;
6 6
7 import 'common/tasks.dart' show CompilerTask;
7 import 'common.dart'; 8 import 'common.dart';
8 import 'common/tasks.dart' show CompilerTask;
9 import 'compile_time_constants.dart' show ConstantCompiler; 9 import 'compile_time_constants.dart' show ConstantCompiler;
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 show 13 show
14 ConstantValue, 14 ConstantValue,
15 ConstructedConstantValue, 15 ConstructedConstantValue,
16 ListConstantValue, 16 ListConstantValue,
17 StringConstantValue, 17 StringConstantValue,
18 TypeConstantValue; 18 TypeConstantValue;
19 import 'dart_types.dart' show DartType, InterfaceType, TypeKind; 19 import 'dart_types.dart' show DartType, InterfaceType;
20 import 'elements/elements.dart' 20 import 'elements/elements.dart'
21 show 21 show
22 ClassElement, 22 ClassElement,
23 Element, 23 Element,
24 ImportElement, 24 ImportElement,
25 LibraryElement, 25 LibraryElement,
26 MetadataAnnotation, 26 MetadataAnnotation,
27 ScopeContainerElement, 27 ScopeContainerElement,
28 VariableElement; 28 VariableElement;
29 import 'resolution/tree_elements.dart' show TreeElements; 29 import 'resolution/tree_elements.dart' show TreeElements;
30 import 'tree/tree.dart' 30 import 'tree/tree.dart' show NamedArgument, NewExpression, Node;
31 show Import, LibraryTag, NamedArgument, NewExpression, Node;
32 31
33 /** 32 /**
34 * Compiler task that analyzes MirrorsUsed annotations. 33 * Compiler task that analyzes MirrorsUsed annotations.
35 * 34 *
36 * When importing 'dart:mirrors', it is possible to annotate the import with 35 * When importing 'dart:mirrors', it is possible to annotate the import with
37 * MirrorsUsed annotation. This is a way to declare what elements will be 36 * MirrorsUsed annotation. This is a way to declare what elements will be
38 * reflected on at runtime. Such elements, even they would normally be 37 * reflected on at runtime. Such elements, even they would normally be
39 * discarded by the implicit tree-shaking algorithm must be preserved in the 38 * discarded by the implicit tree-shaking algorithm must be preserved in the
40 * final output. 39 * final output.
41 * 40 *
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after
564 // @MirrorsUsed(targets: fisk) 563 // @MirrorsUsed(targets: fisk)
565 // ^^^^ 564 // ^^^^
566 // 565 //
567 // Instead of saying 'fisk' should pretty print the problematic constant 566 // Instead of saying 'fisk' should pretty print the problematic constant
568 // value. 567 // value.
569 return spannable; 568 return spannable;
570 } 569 }
571 return node; 570 return node;
572 } 571 }
573 } 572 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/mirrors/dart2js_mirrors.dart ('k') | pkg/compiler/lib/src/native/behavior.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698