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

Unified Diff: sdk/lib/_internal/compiler/implementation/native/js.dart

Issue 694353007: Move dart2js from sdk/lib/_internal/compiler to pkg/compiler (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month 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
Index: sdk/lib/_internal/compiler/implementation/native/js.dart
diff --git a/sdk/lib/_internal/compiler/implementation/native/js.dart b/sdk/lib/_internal/compiler/implementation/native/js.dart
deleted file mode 100644
index 1cbe8da5c8fb978d81a05f35d7e040febc8b2e19..0000000000000000000000000000000000000000
--- a/sdk/lib/_internal/compiler/implementation/native/js.dart
+++ /dev/null
@@ -1,83 +0,0 @@
-// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-part of native;
-
-class SideEffectsVisitor extends js.BaseVisitor {
- final SideEffects sideEffects;
- SideEffectsVisitor(this.sideEffects);
-
- void visit(js.Node node) {
- node.accept(this);
- }
-
- void visitLiteralExpression(js.LiteralExpression node) {
- sideEffects.setAllSideEffects();
- sideEffects.setDependsOnSomething();
- node.visitChildren(this);
- }
-
- void visitLiteralStatement(js.LiteralStatement node) {
- sideEffects.setAllSideEffects();
- sideEffects.setDependsOnSomething();
- node.visitChildren(this);
- }
-
- void visitAssignment(js.Assignment node) {
- sideEffects.setChangesStaticProperty();
- sideEffects.setChangesInstanceProperty();
- sideEffects.setChangesIndex();
- node.visitChildren(this);
- }
-
- void visitVariableInitialization(js.VariableInitialization node) {
- node.visitChildren(this);
- }
-
- void visitCall(js.Call node) {
- sideEffects.setAllSideEffects();
- sideEffects.setDependsOnSomething();
- node.visitChildren(this);
- }
-
- void visitBinary(js.Binary node) {
- node.visitChildren(this);
- }
-
- void visitThrow(js.Throw node) {
- // TODO(ngeoffray): Incorporate a mayThrow flag in the
- // [SideEffects] class.
- sideEffects.setAllSideEffects();
- }
-
- void visitNew(js.New node) {
- sideEffects.setAllSideEffects();
- sideEffects.setDependsOnSomething();
- node.visitChildren(this);
- }
-
- void visitPrefix(js.Prefix node) {
- if (node.op == 'delete') {
- sideEffects.setChangesStaticProperty();
- sideEffects.setChangesInstanceProperty();
- sideEffects.setChangesIndex();
- }
- node.visitChildren(this);
- }
-
- void visitVariableUse(js.VariableUse node) {
- sideEffects.setDependsOnStaticPropertyStore();
- }
-
- void visitPostfix(js.Postfix node) {
- node.visitChildren(this);
- }
-
- void visitAccess(js.PropertyAccess node) {
- sideEffects.setDependsOnIndexStore();
- sideEffects.setDependsOnInstancePropertyStore();
- sideEffects.setDependsOnStaticPropertyStore();
- node.visitChildren(this);
- }
-}

Powered by Google App Engine
This is Rietveld 408576698