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

Side by Side Diff: pkg/compiler/lib/src/serialization/equivalence.dart

Issue 1873823002: Update elements, nodes and visitors for serialization. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Rebased Created 4 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 /// Functions for asserting equivalence across serialization. 5 /// Functions for asserting equivalence across serialization.
6 6
7 library dart2js.serialization.equivalence; 7 library dart2js.serialization.equivalence;
8 8
9 import '../common/resolution.dart'; 9 import '../common/resolution.dart';
10 import '../constants/expressions.dart'; 10 import '../constants/expressions.dart';
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 return checkMembers(element1, element2); 265 return checkMembers(element1, element2);
266 } 266 }
267 267
268 @override 268 @override
269 bool visitLocalFunctionElement( 269 bool visitLocalFunctionElement(
270 LocalFunctionElement element1, LocalFunctionElement element2) { 270 LocalFunctionElement element1, LocalFunctionElement element2) {
271 // TODO(johnniwinther): Define an equivalence on locals. 271 // TODO(johnniwinther): Define an equivalence on locals.
272 return checkMembers(element1.memberContext, element2.memberContext); 272 return checkMembers(element1.memberContext, element2.memberContext);
273 } 273 }
274 274
275 @override
276 bool visitLocalVariableElement(
277 LocalVariableElement element1, LocalVariableElement element2) {
278 // TODO(johnniwinther): Define an equivalence on locals.
279 return checkMembers(element1.memberContext, element2.memberContext);
280 }
281
275 bool visitAbstractFieldElement( 282 bool visitAbstractFieldElement(
276 AbstractFieldElement element1, AbstractFieldElement element2) { 283 AbstractFieldElement element1, AbstractFieldElement element2) {
277 return checkMembers(element1, element2); 284 return checkMembers(element1, element2);
278 } 285 }
279 286
280 @override 287 @override
281 bool visitTypeVariableElement( 288 bool visitTypeVariableElement(
282 TypeVariableElement element1, TypeVariableElement element2) { 289 TypeVariableElement element1, TypeVariableElement element2) {
283 return strategy.test( 290 return strategy.test(
284 element1, element2, 'name', element1.name, element2.name) && 291 element1, element2, 'name', element1.name, element2.name) &&
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
589 impact1, impact2, 'features', impact1.features, impact2.features) && 596 impact1, impact2, 'features', impact1.features, impact2.features) &&
590 strategy.testSets(impact1, impact2, 'listLiterals', impact1.listLiterals, 597 strategy.testSets(impact1, impact2, 'listLiterals', impact1.listLiterals,
591 impact2.listLiterals, areListLiteralUsesEquivalent) && 598 impact2.listLiterals, areListLiteralUsesEquivalent) &&
592 strategy.testSets(impact1, impact2, 'mapLiterals', impact1.mapLiterals, 599 strategy.testSets(impact1, impact2, 'mapLiterals', impact1.mapLiterals,
593 impact2.mapLiterals, areMapLiteralUsesEquivalent) && 600 impact2.mapLiterals, areMapLiteralUsesEquivalent) &&
594 strategy.testSets(impact1, impact2, 'staticUses', impact1.staticUses, 601 strategy.testSets(impact1, impact2, 'staticUses', impact1.staticUses,
595 impact2.staticUses, areStaticUsesEquivalent) && 602 impact2.staticUses, areStaticUsesEquivalent) &&
596 strategy.testSets(impact1, impact2, 'typeUses', impact1.typeUses, 603 strategy.testSets(impact1, impact2, 'typeUses', impact1.typeUses,
597 impact2.typeUses, areTypeUsesEquivalent); 604 impact2.typeUses, areTypeUsesEquivalent);
598 } 605 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/serialization/element_serialization.dart ('k') | pkg/compiler/lib/src/serialization/modelz.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698