Update comment style generic syntax
BUG=
R=kevmoo@google.com
Review-Url: https://codereview.chromium.org//2987963002 .
diff --git a/lib/src/stream_channel_transformer.dart b/lib/src/stream_channel_transformer.dart
index 46232d7..d6d10ff 100644
--- a/lib/src/stream_channel_transformer.dart
+++ b/lib/src/stream_channel_transformer.dart
@@ -41,9 +41,9 @@
/// throws a [CastError]. This also means that calls to [StreamSink.add] on
/// the transformed channel's sink may throw a [CastError] if the argument
/// type doesn't match the reified type of the sink.
- static StreamChannelTransformer/*<S, T>*/ typed/*<S, T>*/(
+ static StreamChannelTransformer<S, T> typed<S, T>(
StreamChannelTransformer transformer) =>
- transformer is StreamChannelTransformer/*<S, T>*/
+ transformer is StreamChannelTransformer<S, T>
? transformer
: new TypeSafeStreamChannelTransformer(transformer);
diff --git a/lib/stream_channel.dart b/lib/stream_channel.dart
index 34be085..dcbc9a0 100644
--- a/lib/stream_channel.dart
+++ b/lib/stream_channel.dart
@@ -108,8 +108,8 @@
/// Transforms [this] using [transformer].
///
/// This is identical to calling `transformer.bind(channel)`.
- StreamChannel/*<S>*/ transform/*<S>*/(
- StreamChannelTransformer<dynamic/*=S*/, T> transformer);
+ StreamChannel<S> transform<S>(
+ StreamChannelTransformer<S, T> transformer);
/// Transforms only the [stream] component of [this] using [transformer].
StreamChannel<T> transformStream(StreamTransformer<T, T> transformer);
@@ -130,7 +130,7 @@
/// If any events emitted by [stream] aren't of type [S], they're converted
/// into [CastError] events. Similarly, if any events are added to [sync] that
/// aren't of type [S], a [CastError] is thrown.
- StreamChannel/*<S>*/ cast/*<S>*/();
+ StreamChannel<S> cast<S>();
}
/// An implementation of [StreamChannel] that simply takes a stream and a sink
@@ -153,8 +153,8 @@
other.stream.pipe(sink);
}
- StreamChannel/*<S>*/ transform/*<S>*/(
- StreamChannelTransformer<dynamic/*=S*/, T> transformer) =>
+ StreamChannel<S> transform<S>(
+ StreamChannelTransformer<S, T> transformer) =>
transformer.bind(this);
StreamChannel<T> transformStream(StreamTransformer<T, T> transformer) =>
@@ -169,6 +169,6 @@
StreamChannel<T> changeSink(StreamSink<T> change(StreamSink<T> sink)) =>
new StreamChannel.withCloseGuarantee(stream, change(sink));
- StreamChannel/*<S>*/ cast/*<S>*/() => new StreamChannel(
+ StreamChannel<S> cast<S>() => new StreamChannel(
DelegatingStream.typed(stream), DelegatingStreamSink.typed(sink));
}
diff --git a/pubspec.yaml b/pubspec.yaml
index 7d395a3..19a3bd0 100644
--- a/pubspec.yaml
+++ b/pubspec.yaml
@@ -1,10 +1,10 @@
name: stream_channel
-version: 1.6.1
+version: 1.6.2-dev
description: An abstraction for two-way communication channels.
author: Dart Team <misc@dartlang.org>
homepage: https://github.com/dart-lang/stream_channel
environment:
- sdk: '>=1.8.0 <2.0.0'
+ sdk: '>=1.21.0 <2.0.0-dev.infinity'
dependencies:
async: '^1.11.0'
stack_trace: '^1.0.0'