Skip to content

Regex \W inconsistency #43928

Open
Open
@miloush

Description

@miloush

Type of issue

Other (describe below)

Description

The \W language element is equivalent to the following character class [^\p{Ll}\p{Lu}\p{Lt}\p{Lo}\p{Nd}\p{Pc}\p{Lm}]

In other words, it matches any character except for those in the Unicode categories listed in the following table.

The table contains \p{Mn} but the equivalent class does not.

Page URL

https://learn.microsoft.com/en-us/dotnet/standard/base-types/character-classes-in-regular-expressions

Content source URL

https://github.com/dotnet/docs/blob/main/docs/standard/base-types/character-classes-in-regular-expressions.md

Document Version Independent Id

95abea42-fa7f-3feb-ae38-049719ab938f

Article author

@adegeo

Metadata

  • ID: a1958bf6-a17d-1256-d659-31066aa02604
  • Service: dotnet-fundamentals

Related Issues

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions