3

I recently edited and got rejected twice for this edit. I've read the editing rules and this seems like a good edit to me. The original code provides no context, nor does it even compile, and the author admits himself that it's untested and theoretical.

From SO Editing Page it reads to me like I'm doing the right thing, but now I'm wondering if there are some unwritten rules about editing that I haven't picked up on yet.

  • 4
    Formatting is not the same as making broken code working code. The latter is a new answer – random Aug 31 '13 at 1:07
  • 1
    The editing page states To correct minor mistakes or add updates as the post ages. The answer is nearly correct, save a few minor mistakes. – Shoe Aug 31 '13 at 1:09
  • 1
    Sure, but something answer-worthy is not a "minor mistake or update". – Dennis Meng Aug 31 '13 at 1:10
  • @Dennis I can see how it would be answer worthy if no answer already existed. A new answer would be almost identical to an existing answer. – Shoe Aug 31 '13 at 1:12
  • If what you are trying to add in is in an existing answer, then definitely do not put it in an edit. – Dennis Meng Aug 31 '13 at 1:13
  • @Dennis I'm not sure what you mean. The original answer was correct, save a few untested mistakes. A new answer would present an entirely different approach/idea, no? – Shoe Aug 31 '13 at 1:15
  • 2
    Not necessarily. If two people are trying roughly the same approach, but one person does it correctly, while the other makes subtle but important mistakes, I'd call them two separate answers. – Dennis Meng Aug 31 '13 at 1:19
  • @Dennis Depends, the answerer repeated it's untested code makes it essentially pseudocode. Assuming that there aren't even mistakes present. – Shoe Aug 31 '13 at 1:26
  • It's not up to someone else to fix someone's untested code. If it's broken, then point it out and get him to fix it. Downvote the post if you think it'll get the point across. But don't fix it for him. – Dennis Meng Aug 31 '13 at 1:29
  • @Dennis Okay, but can you explain what To correct minor mistakes or add updates as the post ages means? I am confused on this point. – Shoe Aug 31 '13 at 1:33
  • Minor mistakes like typos or formatting. Updates as in further research that builds to the post – random Aug 31 '13 at 1:35
  • @random You closed this question as a duplicate of a question about editing code in questions. This meta question is about editing code in an answer, which your proposed duplicate does not discuss. – Gilles 'SO- stop being evil' Aug 31 '13 at 10:28
  • Jim, you were doing the right thing. Editing typed-in-browser code to working code that implements the same solution is a good thing. This is spelled out in the rules of Stack Exchange. Unfortunately, you were the victim of reviewers who feel that the rules don't apply to them. Thank you for the good work, and please continue improving Stack Overflow. Hopefully you'll shortly have enough reputation to do so unhindered. – Gilles 'SO- stop being evil' Aug 31 '13 at 10:29
  • Indeed, Jim, I think your behavior is benchmark. I think some users believe that people who make programming mistakes in their answers should be "punished" by not having their answers improved and that those finding the mistakes should get credit (via separate answers) for finding and fixing them. I don't believe this is in the spirit of SE, while you're behavior most certainly is. Also, I agree this is not a dup, but I don't have the MSO rep to fix that. Keep up the good work and thank you for setting an example for all of us. – Peter Alfvin Aug 31 '13 at 13:50
  • See also my answer to a related question. The fact that this question was closed as a duplicate of an unrelated question is an example of the confusion that is being made between editing code in questions (which is almost always a bad thing) and editing code in answers (which isn't intrinsically good or bad). – Gilles 'SO- stop being evil' Aug 31 '13 at 14:52