This is similar to this question, from a slightly different angle.
One day I get a notification that an edit request has been made to an answer I posted I couple of days earlier. I reviewed the edit, and whoever had made the edit request had changed it so much that it was essentially answering a different question.
I thought I must have a made a mistake, so I cancelled the review and checked the question again, sure enough it had been changed enough to invalidate my answer – but not by the OP, by the same person who had made the edit request to my answer!
This put me in a difficult spot, I completely disagreed with the question edit, but I didn’t want to get into an ‘edit war’ with this person (especially when the OP was very new, it wouldn’t have looked very good). But now I had to agree to my answer’s edits because it’s now wrong, essentially condoning the question edit!
How should I have handled this? Is it OK to flag the question for moderator attention, and complain about edit quality? Or should people who have answered questions be given a say regarding question edits (regardless of who made the edit)?
Editing a question in a way that invalidates existing answers is usually discouraged. There are some exceptions, if the edit saves the question from closure or if the original asker himself clarifies an ambiguous part of the question, such edits are acceptable in my opinion.
In most cases, edits that invalidate existing answers should not be accepted or rolled back. Moving the goalposts afterwards is very unfair to the users that already answered, and it can easily lead to a complete mess. It breaks the voting on answers and can lead to perfectly fine answer being flagged as “not an answer” because someone changed the question.
In this case, the editor tried to read the mind of the asker and changed both the question and answer accordingly. I would generally regard that as not a good idea and both edits should be rolled back. I don’t know Qt, so I can’t really say anything definite for this specific example.
There is no need to involve any moderator, just roll back both edits if they are harmful. Only if the rollback is reversed, a moderator might need to be involved.