How can I prevent interpretation of \u in the replace string

38 Views Asked by At

I want to search for \u00FC and replace it with \u00fc

My search regex is: \u([0-9A-F][0-9A-F][0-9A-F][0-9A-F]) and works fine

The replacement \L$1 does lowercase my 4 characters

However, I cannot find a way to write \u (I think vscode wants it to mean uppercase)

enter image description here

1

There are 1 best solutions below

1
rioV8 On BEST ANSWER

It works by using a positive look behind:

In search bar:

Search: (?<=\\u)((?:[0-9A-F]{4}))

Replace: \L$1


The \\u\L$1 works in the Find Replace dialog (Ctrl+F)

You can file a bug in the VSC repo