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

Side by Side Diff: tests/compiler/dart2js/analyze_unused_dart2js_test.dart

Issue 2797443008: Reapply "Add "load from .dill" file capability and run a white-box test."" (Closed)
Patch Set: take two 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
« no previous file with comments | « pkg/compiler/tool/perf.dart ('k') | tests/compiler/dart2js/dill_loader_test.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) 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 analyze_unused_dart2js; 5 library analyze_unused_dart2js;
6 6
7 import 'package:async_helper/async_helper.dart'; 7 import 'package:async_helper/async_helper.dart';
8 8
9 import 'package:compiler/src/compiler.dart'; 9 import 'package:compiler/src/compiler.dart';
10 import 'package:compiler/src/diagnostics/messages.dart'; 10 import 'package:compiler/src/diagnostics/messages.dart';
11 import 'package:compiler/src/elements/elements.dart' show LibraryElement;
11 import 'package:compiler/src/filenames.dart'; 12 import 'package:compiler/src/filenames.dart';
12 13
13 import 'analyze_helper.dart'; 14 import 'analyze_helper.dart';
14 15
15 // Do not remove WHITE_LIST even if it's empty. The error message for 16 // Do not remove WHITE_LIST even if it's empty. The error message for
16 // unused members refers to WHITE_LIST by name. 17 // unused members refers to WHITE_LIST by name.
17 const Map<String, List<String>> WHITE_LIST = const { 18 const Map<String, List<String>> WHITE_LIST = const {
18 // Helper methods for debugging should never be called from production code: 19 // Helper methods for debugging should never be called from production code:
19 "lib/src/helpers/": const [" is never "], 20 "lib/src/helpers/": const [" is never "],
20 21
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 member.forEachLocalMember(checkLive); 74 member.forEachLocalMember(checkLive);
74 } 75 }
75 } else if (member.isTypedef) { 76 } else if (member.isTypedef) {
76 if (member.isResolved) { 77 if (member.isResolved) {
77 compiler.reporter.reportHintMessage(member, MessageKind.GENERIC, 78 compiler.reporter.reportHintMessage(member, MessageKind.GENERIC,
78 {'text': "Helper typedef in production code '$member'."}); 79 {'text': "Helper typedef in production code '$member'."});
79 } 80 }
80 } 81 }
81 } 82 }
82 83
83 compiler.libraryLoader.lookupLibrary(helperUri).forEachLocalMember(checkLive); 84 (compiler.libraryLoader.lookupLibrary(helperUri) as LibraryElement)
85 .forEachLocalMember(checkLive);
84 return handler.checkResults(); 86 return handler.checkResults();
85 } 87 }
OLDNEW
« no previous file with comments | « pkg/compiler/tool/perf.dart ('k') | tests/compiler/dart2js/dill_loader_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698