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

Side by Side Diff: packages/source_span/lib/src/location_mixin.dart

Issue 2989763002: Update charted to 0.4.8 and roll (Closed)
Patch Set: Removed Cutch from list of reviewers Created 3 years, 4 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
« no previous file with comments | « packages/source_span/lib/src/location.dart ('k') | packages/source_span/lib/src/span.dart » ('j') | 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) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 source_span.location_mixin;
6
7 import 'location.dart'; 5 import 'location.dart';
8 import 'span.dart'; 6 import 'span.dart';
9 7
10 // Note: this class duplicates a lot of functionality of [SourceLocation]. This 8 // Note: this class duplicates a lot of functionality of [SourceLocation]. This
11 // is because in order for SourceLocation to use SourceLocationMixin, 9 // is because in order for SourceLocation to use SourceLocationMixin,
12 // SourceLocationMixin couldn't implement SourceLocation. In SourceSpan we 10 // SourceLocationMixin couldn't implement SourceLocation. In SourceSpan we
13 // handle this by making the class itself non-extensible, but that would be a 11 // handle this by making the class itself non-extensible, but that would be a
14 // breaking change for SourceLocation. So until we want to endure the pain of 12 // breaking change for SourceLocation. So until we want to endure the pain of
15 // cutting a release with breaking changes, we duplicate the code here. 13 // cutting a release with breaking changes, we duplicate the code here.
16 14
(...skipping 25 matching lines...) Expand all
42 bool operator ==(other) => 40 bool operator ==(other) =>
43 other is SourceLocation && 41 other is SourceLocation &&
44 sourceUrl == other.sourceUrl && 42 sourceUrl == other.sourceUrl &&
45 offset == other.offset; 43 offset == other.offset;
46 44
47 int get hashCode => sourceUrl.hashCode + offset; 45 int get hashCode => sourceUrl.hashCode + offset;
48 46
49 String toString() => '<$runtimeType: $offset $toolString>'; 47 String toString() => '<$runtimeType: $offset $toolString>';
50 } 48 }
51 49
OLDNEW
« no previous file with comments | « packages/source_span/lib/src/location.dart ('k') | packages/source_span/lib/src/span.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698