Add none
language strings to code blocks. (#146154)
Part 2 from https://github.com/flutter/flutter/pull/146085 In preparation to add the lint `missing_code_block_language_in_doc_comment`, added `none` info strings to a bunch of fenced code blocks that have miscellaneous text or output text. Related to issue: https://github.com/dart-lang/linter/issues/4904 ## Pre-launch Checklist - [X] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [X] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [X] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement]. - [X] I signed the [CLA]. - [X] I listed at least one issue that this PR fixes in the description above. - [X] I updated/added relevant documentation (doc comments with `///`). - [X] I added new tests to check the change I am making, or this PR is [test-exempt]. - [X] I followed the [breaking change policy] and added [Data Driven Fixes] where supported. - [x] All existing and new tests are passing. If you need help, consider asking for advice on the #hackers-new channel on [Discord]. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/wiki/Tree-hygiene#overview [Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene [test-exempt]: https://github.com/flutter/flutter/wiki/Tree-hygiene#tests [Flutter Style Guide]: https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo [Features we expect every widget to implement]: https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/wiki/Chat [Data Driven Fixes]: https://github.com/flutter/flutter/wiki/Data-driven-Fixes
This commit is contained in:
parent
8b83371e20
commit
972725332f
@ -162,7 +162,7 @@
|
||||
/// }
|
||||
/// ```
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// error (something about backticks)
|
||||
/// this must be the last error, since it aborts parsing of this file
|
||||
/// ```
|
||||
|
@ -25,7 +25,7 @@ const List<String> expectedMainErrors = <String>[
|
||||
'dev/bots/test/analyze-snippet-code-test-input/known_broken_documentation.dart:153:10: (stateful widget) (annotate_overrides)',
|
||||
'dev/bots/test/analyze-snippet-code-test-input/known_broken_documentation.dart:153:10: (stateful widget) (must_call_super)',
|
||||
'dev/bots/test/analyze-snippet-code-test-input/known_broken_documentation.dart:161:7: (top-level declaration) (undefined_identifier)',
|
||||
'dev/bots/test/analyze-snippet-code-test-input/known_broken_documentation.dart:165: Found "```" in code but it did not match RegExp: pattern=^ */// *```dart\$ flags= so something is wrong. Line was: "/// ```"',
|
||||
'dev/bots/test/analyze-snippet-code-test-input/known_broken_documentation.dart:165: Found "```" in code but it did not match RegExp: pattern=^ */// *```dart\$ flags= so something is wrong. Line was: "/// ```none"',
|
||||
'dev/bots/test/analyze-snippet-code-test-input/short_but_still_broken.dart:9:12: (statement) (invalid_assignment)',
|
||||
'dev/bots/test/analyze-snippet-code-test-input/short_but_still_broken.dart:18:4: Empty ```dart block in snippet code.',
|
||||
];
|
||||
|
@ -93,7 +93,7 @@ enum GitExceptionType {
|
||||
///
|
||||
/// Example output:
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// To github.com:user/engine.git
|
||||
///
|
||||
/// ! [rejected] HEAD -> cherrypicks-flutter-2.8-candidate.3 (non-fast-forward)
|
||||
|
@ -80,7 +80,7 @@ class PhysicalKeyData {
|
||||
///
|
||||
/// Lines in this file look like this (without the ///):
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// key 100 ALT_RIGHT
|
||||
/// # key 101 "KEY_LINEFEED"
|
||||
/// key 477 F12 FUNCTION
|
||||
|
@ -395,7 +395,7 @@ class $classNamePrefix$camelCaseName extends $superClass {''';
|
||||
|
||||
/// Return the input string as a Dart-parseable string.
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// foo => 'foo'
|
||||
/// foo "bar" => 'foo "bar"'
|
||||
/// foo 'bar' => "foo 'bar'"
|
||||
@ -407,7 +407,7 @@ class $classNamePrefix$camelCaseName extends $superClass {''';
|
||||
/// in JSON files are escaped. For example, the backspace character (\b)
|
||||
/// has to be properly escaped by this function so that the generated
|
||||
/// Dart code correctly represents this character:
|
||||
/// ```
|
||||
/// ```none
|
||||
/// foo\bar => 'foo\\bar'
|
||||
/// foo\nbar => 'foo\\nbar'
|
||||
/// foo\\nbar => 'foo\\\\nbar'
|
||||
|
@ -877,7 +877,7 @@ Map<String, String> parseAdbDeviceProperties(String str) {
|
||||
///
|
||||
/// Example output:
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// Applications Memory Usage (in Kilobytes):
|
||||
/// Uptime: 441088659 Realtime: 521464097
|
||||
///
|
||||
|
@ -853,7 +853,7 @@ class ManifestAssetBundle implements AssetBundle {
|
||||
/// - assets/bar
|
||||
///
|
||||
/// This will return:
|
||||
/// ```
|
||||
/// ```none
|
||||
/// {
|
||||
/// asset: packages/test_package/assets/foo: [
|
||||
/// asset: packages/test_package/assets/foo,
|
||||
|
@ -210,7 +210,7 @@ const int kMinColumnWidth = 10;
|
||||
/// ```
|
||||
///
|
||||
/// yields:
|
||||
/// ```
|
||||
/// ```none
|
||||
/// Usage: app main_command <subcommand>
|
||||
/// [arguments]
|
||||
/// ```
|
||||
|
@ -1195,7 +1195,7 @@ class PubspecHeader extends PubspecLine {
|
||||
///
|
||||
/// The value of this field extracted from the following line is "version".
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// version: 0.16.5
|
||||
/// ```
|
||||
final String? name;
|
||||
@ -1207,7 +1207,7 @@ class PubspecHeader extends PubspecLine {
|
||||
///
|
||||
/// The value of this field extracted from the following line is "0.16.5".
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// version: 0.16.5
|
||||
/// ```
|
||||
final String? value;
|
||||
@ -1565,7 +1565,7 @@ class PubDependencyTree {
|
||||
///
|
||||
/// That output is of this form:
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// package_name 0.0.0
|
||||
///
|
||||
/// dependencies:
|
||||
|
@ -228,7 +228,7 @@ String describeLocale(String tag) {
|
||||
|
||||
/// Return the input string as a Dart-parsable string.
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// foo => 'foo'
|
||||
/// foo "bar" => 'foo "bar"'
|
||||
/// foo 'bar' => "foo 'bar'"
|
||||
@ -240,7 +240,7 @@ String describeLocale(String tag) {
|
||||
/// in JSON files are escaped. For example, the backspace character (\b)
|
||||
/// has to be properly escaped by this function so that the generated
|
||||
/// Dart code correctly represents this character:
|
||||
/// ```
|
||||
/// ```none
|
||||
/// foo\bar => 'foo\\bar'
|
||||
/// foo\nbar => 'foo\\nbar'
|
||||
/// foo\\nbar => 'foo\\\\nbar'
|
||||
|
@ -30,7 +30,7 @@ import 'migrations/remove_macos_framework_link_and_embedding_migration.dart';
|
||||
/// Passing this regexp to trace moves the stdout output to stderr.
|
||||
///
|
||||
/// Filter out xcodebuild logging unrelated to macOS builds:
|
||||
/// ```
|
||||
/// ```none
|
||||
/// xcodebuild[2096:1927385] Requested but did not find extension point with identifier Xcode.IDEKit.ExtensionPointIdentifierToBundleIdentifier for extension Xcode.DebuggerFoundation.AppExtensionToBundleIdentifierMap.watchOS of plug-in com.apple.dt.IDEWatchSupportCore
|
||||
///
|
||||
/// note: Using new build system
|
||||
|
@ -264,7 +264,7 @@ class _NoContext implements AppContext {
|
||||
///
|
||||
/// Example use:
|
||||
///
|
||||
/// ```
|
||||
/// ```dart
|
||||
/// void main() {
|
||||
/// var handler = FileExceptionHandler();
|
||||
/// var fs = MemoryFileSystem(opHandle: handler.opHandle);
|
||||
|
@ -182,7 +182,7 @@ class FuchsiaRemoteConnection {
|
||||
/// is expected to contain the interface as well (in the event that it is
|
||||
/// link-local), like the following:
|
||||
///
|
||||
/// ```
|
||||
/// ```none
|
||||
/// fe80::1%eth0
|
||||
/// ```
|
||||
///
|
||||
|
Loading…
x
Reference in New Issue
Block a user