Skip to content

Commit df2d267

Browse files
authored
Update docs: Correct 'argument' to 'parameter', fix whitespace & EOF. (#5454)
In some places “argument type” was used and this has been corrected into “parameter type”. Some trailing whitespaces where removed. One file didn’t end in a newline and this has been fixed.
1 parent de76557 commit df2d267

File tree

7 files changed

+21
-21
lines changed

7 files changed

+21
-21
lines changed

CONTRIBUTING.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ More info:
5353

5454
## Updating code samples
5555

56-
If your PR changes Dart code within a page,
56+
If your PR changes Dart code within a page,
5757
you'll probably need to change the code in two places:
5858

5959
1. In a `.md` file for the page.

diagrams/README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
This directory contains sources for generating images used across the website.
44

5-
These come in various forms, such as
6-
`.graffle` used by the [OmniGraffle][] tool
5+
These come in various forms, such as
6+
`.graffle` used by the [OmniGraffle][] tool
77
as well as PNGs and SVGs generated with [diagrams.net][].
88

9-
Do **NOT** optimize any images or vectors that are in this directory.
9+
Do **NOT** optimize any images or vectors that are in this directory.
1010
They contain metadata used by editors to enable editing the image.
1111

1212
[OmniGraffle]: https://www.omnigroup.com/omnigraffle/
13-
[diagrams.net]: https://www.diagrams.net/
13+
[diagrams.net]: https://www.diagrams.net/

src/language/extend.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,10 @@ the method (or methods) that it overrides in several ways:
6262

6363
* The return type must be the same type as (or a subtype of)
6464
the overridden method's return type.
65-
* Argument types must be the same type as (or a supertype of)
66-
the overridden method's argument types.
65+
* Parameter types must be the same type as (or a supertype of)
66+
the overridden method's parameter types.
6767
In the preceding example, the `contrast` setter of `SmartTelevision`
68-
changes the argument type from `int` to a supertype, `num`.
68+
changes the parameter type from `int` to a supertype, `num`.
6969
* If the overridden method accepts _n_ positional parameters,
7070
then the overriding method must also accept _n_ positional parameters.
7171
* A [generic method][] can't override a non-generic one,
@@ -77,10 +77,10 @@ This violates the normal rules, and
7777
it's similar to a downcast in that it can cause a type error at runtime.
7878
Still, narrowing the type is possible
7979
if the code can guarantee that a type error won't occur.
80-
In this case, you can use the
80+
In this case, you can use the
8181
[`covariant` keyword](/guides/language/sound-problems#the-covariant-keyword)
8282
in a parameter declaration.
83-
For details, see the
83+
For details, see the
8484
[Dart language specification][].
8585

8686
{{site.alert.warning}}

src/tools/pub/cmd/pub-get.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ doesn't already contain the dependencies, `dart pub get`
2626
updates the cache,
2727
downloading dependencies if necessary.
2828
To map packages back to the system cache,
29-
this command creates a `package_config.json` file
29+
this command creates a `package_config.json` file
3030
in the `.dart_tool/` directory.
3131

3232
Once the dependencies are acquired, they may be referenced in Dart code.
@@ -63,7 +63,7 @@ in the `.dart_tool/` directory that maps from package names to location URIs.
6363
{{site.alert.note}}
6464
Don't check the generated `.dart_tool/` directory into your repo;
6565
add it to your repo's `.gitignore` file.
66-
For more information,
66+
For more information,
6767
see [What not to commit](/guides/libraries/private-files).
6868
{{site.alert.end}}
6969

src/tools/pub/cmd/pub-global.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ $ dart pub global activate -sgit https://github.com/dart-lang/async_await.git
7474
```
7575

7676
Pub expects to find the package in the root of the Git repository.
77-
To specify a different location,
77+
To specify a different location,
7878
use the `--git-path` option with
7979
a path relative to the repository root:
8080

@@ -229,8 +229,8 @@ For options that apply to all pub commands, see
229229

230230
### `[version-constraint]`
231231

232-
Use `dart pub global activate <package> [version-constraint]`
233-
to specify a specific version of the package.
232+
Use `dart pub global activate <package> [version-constraint]`
233+
to specify a specific version of the package.
234234
For example, the following command pulls
235235
the 0.6.0 version of the `markdown` package:
236236

@@ -259,7 +259,7 @@ to add the specified executable to your PATH.
259259
You can pass more than one of these flags.
260260

261261
For example, the following command adds `bar` and `baz`,
262-
(but not any other executables that `foo` might define)
262+
(but not any other executables that `foo` might define)
263263
to your PATH.
264264

265265
```terminal

src/tools/pub/cmd/pub-outdated.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ you just need to run `dart pub upgrade`:
8181

8282
```terminal
8383
$ dart pub upgrade
84-
Resolving dependencies...
84+
Resolving dependencies...
8585
> args 1.6.0 (was 1.4.4)
8686
...
8787
Changed 1 dependency!
@@ -111,15 +111,15 @@ due to constraints determined by other dependencies:
111111
$ dart pub upgrade
112112
...
113113
$ dart pub outdated
114-
Package Name Current Upgradable Resolvable Latest
114+
Package Name Current Upgradable Resolvable Latest
115115
116116
direct dependencies:
117-
path 1.6.2 1.6.2 1.6.2 1.7.0
117+
path 1.6.2 1.6.2 1.6.2 1.7.0
118118
119119
dev_dependencies: all up-to-date
120120
121121
transitive dependencies:
122-
meta 1.1.6 1.1.6 1.1.6 1.1.8
122+
meta 1.1.6 1.1.6 1.1.6 1.1.8
123123
124124
transitive dev_dependencies: all up-to-date
125125

src/tools/pub/cmd/pub-remove.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ For options that apply to all pub commands, see
3030

3131
### `-n, --dry-run`
3232

33-
Reports which dependencies would change,
33+
Reports which dependencies would change,
3434
but doesn't change any.
3535

3636
### `--[no-]precompile`

0 commit comments

Comments
 (0)