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

Side by Side Diff: pkg/compiler/lib/src/js_backend/codegen/glue.dart

Issue 1153603006: dart2js cps: Type casts and related changes to type propagation. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Another typo in SExpression unstrngifier Created 5 years, 6 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) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 code_generator_dependencies; 5 library code_generator_dependencies;
6 6
7 import '../js_backend.dart'; 7 import '../js_backend.dart';
8 import '../../dart2jslib.dart'; 8 import '../../dart2jslib.dart';
9 import '../../js_emitter/js_emitter.dart'; 9 import '../../js_emitter/js_emitter.dart';
10 import '../../js/js.dart' as js; 10 import '../../js/js.dart' as js;
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 169
170 FunctionElement getAddRuntimeTypeInformation() { 170 FunctionElement getAddRuntimeTypeInformation() {
171 return _backend.getSetRuntimeTypeInfo(); 171 return _backend.getSetRuntimeTypeInfo();
172 } 172 }
173 173
174 /// checkSubtype(value, $isT, typeArgs, $asT) 174 /// checkSubtype(value, $isT, typeArgs, $asT)
175 FunctionElement getCheckSubtype() { 175 FunctionElement getCheckSubtype() {
176 return _backend.getCheckSubtype(); 176 return _backend.getCheckSubtype();
177 } 177 }
178 178
179 /// subtypeCast(value, $isT, typeArgs, $asT)
180 FunctionElement getSubtypeCast() {
181 return _backend.getSubtypeCast();
182 }
183
179 /// checkSubtypeOfRuntime(value, runtimeType) 184 /// checkSubtypeOfRuntime(value, runtimeType)
180 FunctionElement getCheckSubtypeOfRuntime() { 185 FunctionElement getCheckSubtypeOfRuntimeType() {
181 return _backend.getCheckSubtypeOfRuntimeType(); 186 return _backend.getCheckSubtypeOfRuntimeType();
182 } 187 }
183 188
189 /// subtypeOfRuntimeTypeCast(value, runtimeType)
190 FunctionElement getSubtypeOfRuntimeTypeCast() {
191 return _backend.getSubtypeOfRuntimeTypeCast();
192 }
193
184 js.Expression getRuntimeTypeName(ClassElement cls) { 194 js.Expression getRuntimeTypeName(ClassElement cls) {
185 return js.string(_namer.runtimeTypeName(cls)); 195 return js.string(_namer.runtimeTypeName(cls));
186 } 196 }
187 197
188 int getTypeVariableIndex(TypeVariableType variable) { 198 int getTypeVariableIndex(TypeVariableType variable) {
189 return RuntimeTypes.getTypeVariableIndex(variable.element); 199 return RuntimeTypes.getTypeVariableIndex(variable.element);
190 } 200 }
191 201
192 bool needsSubstitutionForTypeVariableAccess(ClassElement cls) { 202 bool needsSubstitutionForTypeVariableAccess(ClassElement cls) {
193 ClassWorld classWorld = _compiler.world; 203 ClassWorld classWorld = _compiler.world;
(...skipping 29 matching lines...) Expand all
223 } 233 }
224 234
225 bool operatorEqHandlesNullArgument(FunctionElement element) { 235 bool operatorEqHandlesNullArgument(FunctionElement element) {
226 return _backend.operatorEqHandlesNullArgument(element); 236 return _backend.operatorEqHandlesNullArgument(element);
227 } 237 }
228 238
229 bool hasStrictSubtype(ClassElement element) { 239 bool hasStrictSubtype(ClassElement element) {
230 return _compiler.world.hasAnyStrictSubtype(element); 240 return _compiler.world.hasAnyStrictSubtype(element);
231 } 241 }
232 } 242 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698