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

Side by Side Diff: sdk/lib/_internal/compiler/implementation/compiler.dart

Issue 12610006: Renamed StreamSink to EventSink. Renamed signalError to addError. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Changed inheritance back! Now create StreamSink instead of EventSink where we create them. Created 7 years, 9 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 | Annotate | Revision Log
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 part of dart2js; 5 part of dart2js;
6 6
7 /** 7 /**
8 * If true, print a warning for each method that was resolved, but not 8 * If true, print a warning for each method that was resolved, but not
9 * compiled. 9 * compiled.
10 */ 10 */
(...skipping 1142 matching lines...) Expand 10 before | Expand all | Expand 10 after
1153 if (condition is Function){ 1153 if (condition is Function){
1154 condition = condition(); 1154 condition = condition();
1155 } 1155 }
1156 if (spannable == null || !condition) { 1156 if (spannable == null || !condition) {
1157 throw new SpannableAssertionFailure(spannable, message); 1157 throw new SpannableAssertionFailure(spannable, message);
1158 } 1158 }
1159 return true; 1159 return true;
1160 } 1160 }
1161 1161
1162 /// A sink that drains into /dev/null. 1162 /// A sink that drains into /dev/null.
1163 class NullSink extends StreamSink<String> { 1163 class NullSink implements EventSink<String> {
1164 final String name; 1164 final String name;
1165 1165
1166 NullSink(this.name); 1166 NullSink(this.name);
1167 1167
1168 add(String value) {} 1168 add(String value) {}
1169 1169
1170 void signalError(AsyncError error) {} 1170 void addError(AsyncError error) {}
1171 1171
1172 void close() {} 1172 void close() {}
1173 1173
1174 toString() => name; 1174 toString() => name;
1175 1175
1176 /// Convenience method for getting an [api.CompilerOutputProvider]. 1176 /// Convenience method for getting an [api.CompilerOutputProvider].
1177 static NullSink outputProvider(String name, String extension) { 1177 static NullSink outputProvider(String name, String extension) {
1178 return new NullSink('$name.$extension'); 1178 return new NullSink('$name.$extension');
1179 } 1179 }
1180 } 1180 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698