I've noticed that after performing an undo the editor doesn't always update error/warning markings. For example if I delete a semi-colon from the end of a line the editor marks the following line with an error, but if I perform an undo command (re-adding the semi-colon) the error marking sometimes doesn't go away.
I'm not sure what causes it to happen, but it seems to happen more often if I open another file and make changes to it before going back to the original file and performing the undo.