@Freon-Sandoz said in Unexpected match when searching files for an end-quote character (non-ASCII):
The text is from a Perl script I wrote long ago. Notepad++ identifies the file as “ANSI” and it appears to be encoded as Windows-1254, although Notepad++ doesn’t identify it as such.
When Notepad++ opens a file as ANSI, it is using the default code page for your system. Is the default code page for your system Windows-1254? (One way to tell would be to copy the Debug Info… from the ? menu. Among other useful diagnostic information, it lists the Current ANSI codepage.)
If your code page is not 1254, then try opening the file in Notepad++ and immediately — before you do anything else! — select Encoding | Character sets | Turkish | Windows-1254. That will cause Notepad++ to reload the file and interpret it using the specified code page.
I’m not convinced that is the problem, though. In the screen shot you included, the quotes look like straight quotes, not typographic quotes. You’ve highlighted the quote mark, but that appears to be just your selection, not the result of a search; I think the search you show in that screen shot will not (and should not) match.
So I think it’s more likely that the problem lies in whatever led you to think that there is a non-ASCII end quote in the file. You say you didn’t expect a curly quote and it looks like you don’t have one. What sort of file search did you do that led you to think there was one?