开发者

emacs: is there a way to specify a case-insensitive search in a regexp?

开发者 https://www.devze.com 2023-01-01 11:19 出处:网络
In Javascript, I just need to append a i to the regexp to make it case-insensitive.In .NET, I use a RegexOptions.IgnoreCase.

In Javascript, I just need to append a i to the regexp to make it case-insensitive. In .NET, I use a RegexOptions.IgnoreCase.

I know about case-fold-search. What I want is to specify that behavior in the regex itself, as specified in a开发者_JAVA百科n elisp program. Possible?


As someone said earlier, the way to control this is to bind case-fold-search. There is no way to specify the regex's case-sensitivity (or lack thereof) in the regex itself.

As it happens, regexp matching is already case-insensitive by default.

0

精彩评论

暂无评论...
验证码 换一张
取 消