dotnet / dotnet/dotnet-api-docs
System.Linq.Enumerable.Repeat method: Explanation for count argument slightly inaccurate (nitpicking)
- Vorherrschende Sprache
- C#
- Sterne
- 949
- Forks
- 1.7k
- Ø Merge
- 2 T. 19 Std.
- Gemergte PRs (30 T.)
- 52
Beschreibung
I admit, this issue report is on the verge of nitpicking, but nevertheless...
The `count` argument for the `Enumerable.Repeat` method currently states:
> _The number of times to repeat the value in the generated sequence_
This is of course incorrect :)
In fact, the value is repeated `count-1` times in the generated sequence; when `count` is being 0 the generated sequence is empty.
A more accurate description for the `count` argument could perhaps be something like:
> _The number of times the value occurs in the generated sequence_
----
Github link to the respective line in the documentation source: https://github.com/dotnet/dotnet-api-docs/blob/739ea290c4423665b5f06ca6938b75c8b5b6e11b/xml/System.Linq/Enumerable.xml#L8566
Link to documentation: https://docs.microsoft.com/en-us/dotnet/api/system.linq.enumerable.repeat?view=netstandard-2.1
Beitragsleitfaden
Rechercherichtung
Öffne xml/System.Linq/Enumerable.xml in der Nähe von Zeile 8566 und überprüfe die Beschreibung des count-Arguments für Enumerable.Repeat. Aktualisiere sie so, dass sie korrekt angibt, wie oft der Wert vorkommt, einschließlich des Falls von count gleich null. Erledigt ist die Aufgabe, wenn die Parameterformulierung dem Verhalten der Methode entspricht und die generierte API-Dokumentation die Korrektur widerspiegelt.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- csharp
- Bereich
- documentation
- Issue-Typ
- Dokumentation
- Schwierigkeit
- 1/5
- Geschätzter Aufwand
- Unter einer Stunde
- Aktivitätsstatus
- Veraltet
- Klarheit
- Klar beschrieben
- Anfängerfreundlichkeit
- 72/100