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

Side by Side Diff: pkg/analyzer/test/generated/test_support.dart

Issue 2050083002: Fix equality between subclasses of Source (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 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 analyzer.test.generated.test_support; 5 library analyzer.test.generated.test_support;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 8
9 import 'package:analyzer/dart/ast/ast.dart' show AstNode, SimpleIdentifier; 9 import 'package:analyzer/dart/ast/ast.dart' show AstNode, SimpleIdentifier;
10 import 'package:analyzer/dart/element/element.dart'; 10 import 'package:analyzer/dart/element/element.dart';
(...skipping 582 matching lines...) Expand 10 before | Expand all | Expand 10 after
593 } 593 }
594 594
595 @override 595 @override
596 int get modificationStamp => 596 int get modificationStamp =>
597 generateExceptionOnRead ? -1 : _modificationStamp; 597 generateExceptionOnRead ? -1 : _modificationStamp;
598 598
599 String get shortName { 599 String get shortName {
600 return _name; 600 return _name;
601 } 601 }
602 602
603 Uri get uri { 603 Uri get uri => new Uri.file(_name);
604 throw new UnsupportedOperationException();
605 }
606 604
607 UriKind get uriKind { 605 UriKind get uriKind {
608 throw new UnsupportedOperationException(); 606 throw new UnsupportedOperationException();
609 } 607 }
610 608
611 bool operator ==(Object other) { 609 bool operator ==(Object other) {
612 if (other is TestSource) { 610 if (other is TestSource) {
613 return other._name == _name; 611 return other._name == _name;
614 } 612 }
615 return false; 613 return false;
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
653 return UriKind.FILE_URI; 651 return UriKind.FILE_URI;
654 } 652 }
655 653
656 bool operator ==(Object other) { 654 bool operator ==(Object other) {
657 if (other is TestSource) { 655 if (other is TestSource) {
658 return other.uri == uri; 656 return other.uri == uri;
659 } 657 }
660 return false; 658 return false;
661 } 659 }
662 } 660 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/summary/package_bundle_reader.dart ('k') | pkg/analyzer/test/src/context/context_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698