Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect work of substitution filters #2335

Open
ivti81 opened this issue May 24, 2024 · 3 comments
Open

Incorrect work of substitution filters #2335

ivti81 opened this issue May 24, 2024 · 3 comments

Comments

@ivti81
Copy link

ivti81 commented May 24, 2024

I'm trying to compare 2 XML files with ignoring XML comments. To do this I've created substitution filter by using regular expressions:

^<!--[\s\S]*-->$

If XML comments are in both files it works OK, but when XML comment absent in of the file, WinMerge consider them as unequal. Files to compare and screenshot are attached.
winmergebug.zip
Screenshot

WinMerge version: 2.16.40.0 X 64
Config file:
WinMerge.txt

@sdottaka
Copy link
Member

Unfortunately, the current WinMerge has a weakness in processing files that do not have a newline character at the end of the file, like the one you attached.
If there is a newline character at the end of the file on the right and the "Ignore blank lines" option is enabled as shown in the image below, you will get the expected result.

image

@ivti81
Copy link
Author

ivti81 commented May 27, 2024

Thank for prompt reply. Will this weakness be fixed it future releases?

@sdottaka
Copy link
Member

If it were to be fixed, it would be a relatively large fix and would not be released immediately.

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

No branches or pull requests

2 participants