dotnet / dotnet/dotnet-api-docs

IsWhiteSpace() for empty spans.

Open
#11,560 1 comment 0 reactions 0 assignees View on GitHub
area-System.Memory untriaged
Dominant language
C#
Stars
949
Forks
1.7k
Avg merge
3d 27m
Merged PRs (30d)
49

Description

### Type of issue

Typo

### Description

The wording is:
`true if the span contains only whitespace characters, false otherwise.`
This implies that empty spans, which do not contain any characters at all, yield false when IsWhiteSpace in fact yields true.
More explicit wording:

`true if the span is empty or contains only whitespace characters, false otherwise.`

### Page URL

https://learn.microsoft.com/en-us/dotnet/api/System.MemoryExtensions.IsWhiteSpace?view=net-9.0

### Content source URL

https://github.com/dotnet/dotnet-api-docs/blob/main/xml/System/MemoryExtensions.xml

### Document Version Independent Id

2318923a-084f-0df8-959f-f66589448a3e

### Platform Id

1c5f2f81-1e6a-67d8-a434-5ec221f08be4

### Article author

@dotnet-bot

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.