4 ms·
I don't relate to this at all. I don't understand how you refactor, in either python or C or anything else, without fixing indentation after you move code aroun
by sanderjd 2y ago
I don't relate to this at all. I don't understand how you refactor, in either python or C or anything else, without fixing indentation after you move code around. Yes, in C you don't have to fix the indentation in order to get it to compile and run, but that doesn't mean you don't have to fix the indentation! You can't just leave it inconsistent, that's insanity.
- wakamoleguy 2y agoOf course you can leave it inconsistent! If whitespace is insignificant, you can move things around however you want and use (frequent) runs of a code formatter to clean things up for you. If whitespace is significant, it must be fixed manually line by line.
- sanderjd 2y agoCode formatters work just fine in python. If you're running a code formatter frequently, that is not "leaving it inconsistent".
- wakamoleguy 2y agoIf we’re talking about pasted code not having the proper indentation, that’s a major difference between languages with and without significant whitespace. A formatter can fix that in C, but not in Python. Additionally, manual fixing of the indentation is required first.
- sanderjd 2y agoI just don't think this is really a problem. My editor doesn't actually have trouble putting pasted code at the right indentation level...