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

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

Issue 23883004: Fix bug http://code.google.com/p/dart/issues/detail?id=12941 by doing speculative optimizations eve… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « tests/compiler/dart2js/bailout_indexable_test.dart ('k') | no next file » | 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 mock_compiler; 5 library mock_compiler;
6 6
7 import "package:expect/expect.dart"; 7 import "package:expect/expect.dart";
8 import 'dart:async'; 8 import 'dart:async';
9 import 'dart:collection'; 9 import 'dart:collection';
10 10
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 95
96 const String DEFAULT_INTERCEPTORSLIB = r''' 96 const String DEFAULT_INTERCEPTORSLIB = r'''
97 class Interceptor { 97 class Interceptor {
98 toString() {} 98 toString() {}
99 bool operator==(other) => identical(this, other); 99 bool operator==(other) => identical(this, other);
100 get hashCode => throw "Interceptor.hashCode not implemented."; 100 get hashCode => throw "Interceptor.hashCode not implemented.";
101 noSuchMethod(im) { throw im; } 101 noSuchMethod(im) { throw im; }
102 } 102 }
103 abstract class JSIndexable { 103 abstract class JSIndexable {
104 get length; 104 get length;
105 operator[](index);
105 } 106 }
106 abstract class JSMutableIndexable extends JSIndexable {} 107 abstract class JSMutableIndexable extends JSIndexable {}
107 class JSArray extends Interceptor implements List, JSIndexable { 108 class JSArray extends Interceptor implements List, JSIndexable {
108 var length; 109 var length;
109 operator[](index) => this[index]; 110 operator[](index) => this[index];
110 operator[]=(index, value) {} 111 operator[]=(index, value) {}
111 add(value) {} 112 add(value) {}
112 removeAt(index) {} 113 removeAt(index) {}
113 insert(index, value) {} 114 insert(index, value) {}
114 removeLast() {} 115 removeLast() {}
(...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after
468 } 469 }
469 } 470 }
470 471
471 class MockDeferredLoadTask extends DeferredLoadTask { 472 class MockDeferredLoadTask extends DeferredLoadTask {
472 MockDeferredLoadTask(Compiler compiler) : super(compiler); 473 MockDeferredLoadTask(Compiler compiler) : super(compiler);
473 474
474 void registerMainApp(LibraryElement mainApp) { 475 void registerMainApp(LibraryElement mainApp) {
475 // Do nothing. 476 // Do nothing.
476 } 477 }
477 } 478 }
OLDNEW
« no previous file with comments | « tests/compiler/dart2js/bailout_indexable_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698