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

Side by Side Diff: pkg/analysis_server/lib/src/services/correction/levenshtein.dart

Issue 2894883002: Remove more libraries directives from server (Closed)
Patch Set: Created 3 years, 7 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 library levenshtein; 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
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.
2 4
3 import 'dart:math' as math; 5 import 'dart:math' as math;
4 6
5 /** 7 /**
6 * The value returned by [levenshtein] if the distance is determined 8 * The value returned by [levenshtein] if the distance is determined
7 * to be over the specified threshold. 9 * to be over the specified threshold.
8 */ 10 */
9 const int LEVENSHTEIN_MAX = 1 << 20; 11 const int LEVENSHTEIN_MAX = 1 << 20;
10 12
11 const int _MAX_VALUE = 1 << 10; 13 const int _MAX_VALUE = 1 << 10;
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 } 124 }
123 125
124 return LEVENSHTEIN_MAX; 126 return LEVENSHTEIN_MAX;
125 } 127 }
126 128
127 void _setRange(List<int> a, int start, int end, int value) { 129 void _setRange(List<int> a, int start, int end, int value) {
128 for (int i = start; i < end; i++) { 130 for (int i = start; i < end; i++) {
129 a[i] = value; 131 a[i] = value;
130 } 132 }
131 } 133 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698