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

Side by Side Diff: runtime/lib/errors_patch.dart

Issue 2563633002: Make the VM's dart:core and dart:async library patches clean. (Closed)
Patch Set: Make moveNextFn private. Created 4 years 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 @patch class Error { 5 @patch class Error {
6 @patch static String _objectToString(Object object) { 6 @patch static String _objectToString(Object object) {
7 return Object._toString(object); 7 return Object._toString(object);
8 } 8 }
9 9
10 @patch static String _stringToSafeString(String string) { 10 @patch static String _stringToSafeString(String string) {
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 final int _line; 96 final int _line;
97 final int _column; 97 final int _column;
98 final String _errorMsg; 98 final String _errorMsg;
99 } 99 }
100 100
101 @patch class FallThroughError { 101 @patch class FallThroughError {
102 FallThroughError._create(this._url, this._line); 102 FallThroughError._create(this._url, this._line);
103 103
104 static _throwNew(int case_clause_pos) native "FallThroughError_throwNew"; 104 static _throwNew(int case_clause_pos) native "FallThroughError_throwNew";
105 105
106 @patch
106 String toString() { 107 String toString() {
107 return "'$_url': Switch case fall-through at line $_line."; 108 return "'$_url': Switch case fall-through at line $_line.";
108 } 109 }
109 110
110 // These new fields cannot be declared final, because a constructor exists 111 // These new fields cannot be declared final, because a constructor exists
111 // in the original version of this patched class. 112 // in the original version of this patched class.
112 String _url; 113 String _url;
113 int _line; 114 int _line;
114 } 115 }
115 116
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 return msg_buf.toString(); 357 return msg_buf.toString();
357 } 358 }
358 } 359 }
359 360
360 361
361 class _CompileTimeError extends Error { 362 class _CompileTimeError extends Error {
362 final String _errorMsg; 363 final String _errorMsg;
363 _CompileTimeError(this._errorMsg); 364 _CompileTimeError(this._errorMsg);
364 String toString() => _errorMsg; 365 String toString() => _errorMsg;
365 } 366 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698