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

Unified Diff: pkg/compiler/lib/src/js_backend/backend.dart

Issue 2997413002: Support --use-kernel in memory_compiler (Closed)
Patch Set: Remove hack in source_loader Created 3 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/compiler/dart2js/compiler_helper.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_backend/backend.dart
diff --git a/pkg/compiler/lib/src/js_backend/backend.dart b/pkg/compiler/lib/src/js_backend/backend.dart
index 611a64747fb4d671568b5c0105b1c11743a953dc..31f90dce47de76005565622f3905c470038a3ce5 100644
--- a/pkg/compiler/lib/src/js_backend/backend.dart
+++ b/pkg/compiler/lib/src/js_backend/backend.dart
@@ -911,8 +911,9 @@ class JavaScriptBackend {
*
* Invariant: [element] must be a declaration element.
*/
- String getGeneratedCode(Element element) {
- assert(element.isDeclaration, failedAt(element));
+ String getGeneratedCode(MemberEntity element) {
+ assert(!(element is MemberElement && !element.isDeclaration),
+ failedAt(element));
return jsAst.prettyPrint(generatedCode[element], compiler.options);
}
« no previous file with comments | « no previous file | tests/compiler/dart2js/compiler_helper.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698