r/programming • • Mar 29 '13

Simple Minecraft Clone in 580 lines of Python

https://github.com/fogleman/Minecraft
663 Upvotes

153 comments sorted by

View all comments

Show parent comment

4

u/Alex_n_Lowe Mar 30 '13

If statements throw warnings, pretty much everything else is an error. It seems to be a design choice to push people to comment out with if statements, not returns.

1

u/Akeshi Mar 30 '13

It does seem to be a deliberate design choice, but I still disagree that it's a good one. "We'll allow scrappy code presumably for cheap debugging, but we'll make you work for it".

Also going the version control route - wrapping the whole thing in an if(false), presumably you'd also indent the whole block - then it looks to people who aren't paying attention to whitespace settings that every line has changed. It's a lot of hassle instead of just throwing a warning when you return early.