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

Side by Side Diff: sdk/lib/math/point.dart

Issue 2968413002: Revert "Use relative URIs for core library part-of statements." (Closed)
Patch Set: Created 3 years, 5 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 | « sdk/lib/math/jenkins_smi_hash.dart ('k') | sdk/lib/math/random.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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 part of dart.math;
5 part of "math.dart";
6 5
7 /** 6 /**
8 * A utility class for representing two-dimensional positions. 7 * A utility class for representing two-dimensional positions.
9 */ 8 */
10 class Point<T extends num> { 9 class Point<T extends num> {
11 final T x; 10 final T x;
12 final T y; 11 final T y;
13 12
14 const Point(T x, T y) 13 const Point(T x, T y)
15 : this.x = x, 14 : this.x = x,
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 * 82 *
84 * Squared distances can be used for comparisons when the actual value is not 83 * Squared distances can be used for comparisons when the actual value is not
85 * required. 84 * required.
86 */ 85 */
87 T squaredDistanceTo(Point<T> other) { 86 T squaredDistanceTo(Point<T> other) {
88 var dx = x - other.x; 87 var dx = x - other.x;
89 var dy = y - other.y; 88 var dy = y - other.y;
90 return dx * dx + dy * dy; 89 return dx * dx + dy * dy;
91 } 90 }
92 } 91 }
OLDNEW
« no previous file with comments | « sdk/lib/math/jenkins_smi_hash.dart ('k') | sdk/lib/math/random.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698