Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

\h and \H regex shorthand character classes are inverted #1023

Closed
1 task done
ghost opened this issue May 23, 2018 · 2 comments
Closed
1 task done

\h and \H regex shorthand character classes are inverted #1023

ghost opened this issue May 23, 2018 · 2 comments

Comments

@ghost
Copy link

ghost commented May 23, 2018

@dinatih commented on May 23, 2018, 7:31 PM UTC:

Prerequisites

Description

\h and \H regex shorthand character classes are inverted

Steps to Reproduce

2018-05-23 21 28 00

Expected behavior: [What you expect to happen]

  • \h should match hexadecimal-digit character which matches [0-9a-fA-F]
  • \H should match non-hexadecimal-digit character

Actual behavior: [What actually happens]

  • \h matches non-hexadecimal-digit character
  • \H matches hexadecimal-digit character which matches [0-9a-fA-F]

Reproduces how often: [What percentage of the time does it reproduce?]
Everytime

Versions

1.27.1

Additional Information

https://raw.githubusercontent.com/kkos/oniguruma/master/doc/RE

This issue was moved by rsese from atom/atom/issues/17400.

@rsese
Copy link

rsese commented May 24, 2018

Thanks for the report @dinatih:

https://raw.githubusercontent.com/kkos/oniguruma/master/doc/RE

Atom find and replace doesn't use Oniguruma e.g. see:

#571

I think \h and \H are character classes for horizontal whitespace?

Let me know if I'm misunderstanding anything.

@rsese rsese closed this as completed May 24, 2018
@dinatih
Copy link

dinatih commented May 24, 2018

Oh, alright, thank you.

http://www.rexegg.com/regex-quickstart.html#whitespace

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants