Announcement
Collapse
No announcement yet.
Python 3.4 Steps Closer With New Features
Collapse
X
-
Originally posted by kigurai View PostAnd there's your problem right there
Yes, the indentation-controls-scope feature of Python is a bit scary when you start. And it is horrible when you have very long blocks of code.
But the neat thing is that since that is horrible, you will actively try to make your blocks of code shorter which usually means prettier and more understandable.
EDIT:
Also, the problem with scope and long blocks of code is primarily when they are both long and have deep nestings. So avoid long deep nestings
Comment
-
Originally posted by curaga View PostIt's a stupid solution for a bunch of reasons in addition to those you listed. It breaks copy-paste, and it breaks when people use different editors (yes, some editors have tab-spaces conversions enabled by default; that's bad too, but it's a fact still).
I'll gladly trade "breaks copy-paste when copying bad code" for all the good things that I get.
Comment
-
Originally posted by curaga View PostI disagree, Python is the very example of languages that force things on people. Let's start with its absolutely horrible forced indentation.
Comment
-
Originally posted by alcalde View PostYour list probably ends there too, but... there is no "forced indentation". Indentation is a requirement to make code readable. Are you suggesting you code without any indentation? No one who writes code with the intention of anyone (including themselves) looking at it again indents code. So what's the problem? You're not being forced to do something you were going to do anyway.
Comment
-
Originally posted by alcalde View PostYour list probably ends there too, but... there is no "forced indentation". Indentation is a requirement to make code readable. Are you suggesting you code without any indentation? No one who writes code with the intention of anyone (including themselves) looking at it again indents code. So what's the problem? You're not being forced to do something you were going to do anyway.
Comment
-
Originally posted by curaga View PostI write indentation how I like it. Python would force me to use a _specific_ type of indentation, which I find horribly ugly. So yes, it would force me to do something I would not otherwise do.
Comment
-
Originally posted by curaga View PostI write indentation how I like it. Python would force me to use a _specific_ type of indentation, which I find horribly ugly. So yes, it would force me to do something I would not otherwise do.
Comment
Comment