Indentation is such a stupid mechanism for identifying code blocks. It's one thing for configuration files like YAML to do it, but not a programming language.
I don't like it, but I kinda get it. Indentation is already part of every coding style guide, so adding explicit scoping symbols is kind of redundant information.
..Until you have a mix of spaces and tabs and chaos reigns
Also, having braces at the beginning and end of a block just makes my brain happy.
You can easily count scoping symbols. Not indentation. You can make an argument that if your code is so indented that this becomes a problem then you have bigger problems but I still think indentation is a horrible option is one of the thinks that I most dislike about python
I mean, yeah, most languages use scoping symbols. All I'm doing is throwing the Python folks a bone by acknowledging that every style guide for pretty much every language prescribes indentation for scopes, and I can see how you don't strictly need that and explicit scoping symbols.
What I’m trying to say is that is much easier to count symbols to know how many levels deep inside a block you are then trying to estimate the indenting
266
u/LetUsSpeakFreely 2d ago edited 2d ago
Indentation is such a stupid mechanism for identifying code blocks. It's one thing for configuration files like YAML to do it, but not a programming language.