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

Unified Diff: lib/src/graph/package_graph.dart

Issue 2993093002: package barback: Update the comment style generic syntax. (Closed)
Patch Set: fix code Created 3 years, 4 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 | « lib/src/asset/asset_node.dart ('k') | lib/src/graph/phase.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/graph/package_graph.dart
diff --git a/lib/src/graph/package_graph.dart b/lib/src/graph/package_graph.dart
index 862dbd721b3018eb385d6cce6dd3c8310c52ef87..8eec163c5ef0dbc0ec2f33f3b4d7ef8f3859a129 100644
--- a/lib/src/graph/package_graph.dart
+++ b/lib/src/graph/package_graph.dart
@@ -127,7 +127,7 @@ class PackageGraph {
///
/// If the asset cannot be found, returns null.
Future<AssetNode> getAssetNode(AssetId id) {
- return _inErrorZone/*<Future<AssetNode>>*/(() {
+ return _inErrorZone<Future<AssetNode>>(() {
var cascade = _cascades[id.package];
if (cascade != null) return cascade.getAssetNode(id);
return new Future.value(null);
@@ -158,7 +158,7 @@ class PackageGraph {
if (_status != NodeStatus.IDLE) {
// A build is still ongoing, so wait for it to complete and try again.
- return results.first.then/*<Future<AssetSet>>*/((_) => getAllAssets());
+ return results.first.then<Future<AssetSet>>((_) => getAllAssets());
}
// If an unexpected error occurred, complete with that.
@@ -274,8 +274,8 @@ class PackageGraph {
/// [Future]. If it throws a [BarbackException], that exception will be piped
/// to the returned [Future] as well. Any other exceptions will be piped to
/// [results].
- Future/*<T>*/ _inErrorZone/*<T>*/(/*=T*/ body()) {
- var completer = new Completer/*<T>*/ .sync();
+ Future<T> _inErrorZone<T>(T body()) {
+ var completer = new Completer<T>.sync();
runZoned(() {
new Future.sync(body)
.then(completer.complete)
« no previous file with comments | « lib/src/asset/asset_node.dart ('k') | lib/src/graph/phase.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698