From 1a6f499bc1621db11cc5b5fae09d7fad139a94f1 Mon Sep 17 00:00:00 2001 From: pq Date: Thu, 19 May 2016 10:21:38 -0700 Subject: [PATCH] Cleanup dangling comment references. Quick pass at fixing a few dangling references as revealed by the new `comment_references` lint (https://github.com/dart-lang/linter/issues/240). There's a bunch more to do here before we can turn it on by default (~430 lints as of now). Many of them are a simple matter of adding an import (e.g., `dart:async` for library docs that reference `Future`) but others will require a bit of thought. Probably best done by the folks writing the code. :) --- packages/flutter_markdown/lib/src/markdown_style.dart | 1 + packages/flutter_markdown/lib/src/markdown_style_raw.dart | 1 + packages/flutter_sprites/lib/src/constraint.dart | 4 ++-- packages/flutter_tools/lib/executable.dart | 2 +- packages/flutter_tools/lib/src/device.dart | 4 ++-- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/packages/flutter_markdown/lib/src/markdown_style.dart b/packages/flutter_markdown/lib/src/markdown_style.dart index b2281b68c0c..357fbae8b5f 100644 --- a/packages/flutter_markdown/lib/src/markdown_style.dart +++ b/packages/flutter_markdown/lib/src/markdown_style.dart @@ -3,6 +3,7 @@ // found in the LICENSE file. import 'package:flutter/material.dart'; +import 'markdown.dart'; import 'markdown_style_raw.dart'; /// Style used for rendering markdown formatted text using the [MarkdownBody] diff --git a/packages/flutter_markdown/lib/src/markdown_style_raw.dart b/packages/flutter_markdown/lib/src/markdown_style_raw.dart index 2bcac360832..1d25924c74a 100644 --- a/packages/flutter_markdown/lib/src/markdown_style_raw.dart +++ b/packages/flutter_markdown/lib/src/markdown_style_raw.dart @@ -3,6 +3,7 @@ // found in the LICENSE file. import 'package:flutter/widgets.dart'; +import 'markdown.dart'; /// Style used for rendering markdown formatted text using the [MarkdownBody] /// widget. diff --git a/packages/flutter_sprites/lib/src/constraint.dart b/packages/flutter_sprites/lib/src/constraint.dart index 05dfd536d20..278b04b3630 100644 --- a/packages/flutter_sprites/lib/src/constraint.dart +++ b/packages/flutter_sprites/lib/src/constraint.dart @@ -5,8 +5,8 @@ part of flutter_sprites; /// constraints property. /// /// Constrains are applied after the update calls are -/// completed. They can also be applied at any time by calling a [Node]'s -/// [applyConstraints] method. It's possible to create custom constraints by +/// completed. They can also be applied at any time by calling +/// [Node.applyConstraints]. It's possible to create custom constraints by /// overriding this class and implementing the [constrain] method. abstract class Constraint { /// Called before the node's update method is called. This method can be diff --git a/packages/flutter_tools/lib/executable.dart b/packages/flutter_tools/lib/executable.dart index 70b9a06517e..5c03af96ef7 100644 --- a/packages/flutter_tools/lib/executable.dart +++ b/packages/flutter_tools/lib/executable.dart @@ -42,7 +42,7 @@ import 'src/runner/flutter_command_runner.dart'; /// Main entry point for commands. /// -/// This function is intended to be used from the [flutter] command line tool. +/// This function is intended to be used from the `flutter` command line tool. Future main(List args) async { bool help = args.contains('-h') || args.contains('--help'); bool verbose = args.contains('-v') || args.contains('--verbose'); diff --git a/packages/flutter_tools/lib/src/device.dart b/packages/flutter_tools/lib/src/device.dart index 72512295bda..954a5d5e15a 100644 --- a/packages/flutter_tools/lib/src/device.dart +++ b/packages/flutter_tools/lib/src/device.dart @@ -247,7 +247,7 @@ class DebuggingOptions { bool get hasObservatoryPort => observatoryPort != null; /// Return the user specified observatory port. If that isn't available, - /// return [defaultObservatoryPort], or a port close to that one. + /// return [kDefaultObservatoryPort], or a port close to that one. Future findBestObservatoryPort() { if (hasObservatoryPort) return new Future.value(observatoryPort); @@ -257,7 +257,7 @@ class DebuggingOptions { bool get hasDiagnosticPort => diagnosticPort != null; /// Return the user specified diagnostic port. If that isn't available, - /// return [defaultObservatoryPort], or a port close to that one. + /// return [kDefaultDiagnosticPort], or a port close to that one. Future findBestDiagnosticPort() { return findPreferredPort(diagnosticPort ?? kDefaultDiagnosticPort); }