For snippets, create a filter with the following pattern:
/*aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaर्वर्वर्वर्वर्वर्वर्वbccccccccccccc*/
and run a regex search for "bc". You'll see that the highlighted portion of the string is not "bc", due to special characters. This is due to preg_match, which returns a mb unsafe offset. I'm not sure what the best replacement would be, though.
As for Ace, go editing the above filter using Ace and move to the end of the line: you'll see some whitespace between the end of the string and the caret, again because special character aren't properly handled. I still have to determine whether this is an Ace bug (hard to believe) or we just need to set an appropriate encoding. EDIT: This seems to be https://github.com/ajaxorg/ace/issues/3037.