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

Unified Diff: runtime/lib/print_patch.dart

Issue 10928145: Patch print directly in corelib instead of going through coreimpl. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/lib/lib_sources.gypi ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/print_patch.dart
diff --git a/runtime/lib/print_patch.dart b/runtime/lib/print_patch.dart
index 6d8c480b7fcc303b907dfc787ae65f4eaef83f77..6ae59f13c2f13be36217d5795e35a1016ef70234 100644
--- a/runtime/lib/print_patch.dart
+++ b/runtime/lib/print_patch.dart
@@ -2,19 +2,16 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-
typedef void _PrintClosure(Object obj);
-patch class PrintImplementation {
- /* patch */ static void print(Object obj) {
- _printClosure(obj.toString());
- }
-
- static void _unsupportedPrint(Object obj) {
- throw const UnsupportedOperationException("'print' is not supported");
- }
+patch void print(Object obj) {
+ _printClosure(obj.toString());
+}
- // _printClosure can be overwritten by the embedder to supply a different
- // print implementation.
- static _PrintClosure _printClosure = _unsupportedPrint;
+void _unsupportedPrint(Object obj) {
+ throw const UnsupportedOperationException("'print' is not supported");
}
+
+// _printClosure can be overwritten by the embedder to supply a different
+// print implementation.
+_PrintClosure _printClosure = _unsupportedPrint;
« no previous file with comments | « runtime/lib/lib_sources.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698