I work in high frequency trading - I'm sure many would try to disbar me if we had a bar.
Since lawyers deal in argument, I think they are better at knowing where to draw lines like this. Reading HN or worse /. I don't think developers can do this well. I used to poke around legal forums a lot and their discussions were much better and well argued compared to dev forums
You're on the right track. These moral codes are supposed to get people thinking whether their acts are really ethical, or just rationalized as such.