Switched to python.
To me that makes sense, since the code looked like a mix of python and a c-based language. Others felt that edit shouldn't have been approved.
The solution is that code suggested edits, if they have an edit comment that makes logical/obvious sense, should just be approved. If there's a problem, well, the answerer whose code was edited will get a notification of the edit, and they can easily roll it back if it's wrong.
It seems that the consensus is that answers should typically contain code in the same language as the question.
Should we just reject the suggested edit, and optionally downvote and/or comment instead?