3 ms·
FYI, I have no idea if I use tabs or spacves in my projects, my IDE is configured to use the popular linting/formatting so it autoformats using that, Honest qu
by simion314 7y ago
FYI, I have no idea if I use tabs or spacves in my projects, my IDE is configured to use the popular linting/formatting so it autoformats using that,
Honest question, when you hit issues caused by someone else code not using your favorite style of tab vs spaces? Is there an editor/IDE that can't autodetect this and work properly or is there a language that would fail because is hyper sensitive to white space?
- kbanana 7y agoPython, which this program is written in, uses indentation for blocks. Mixing spaces and tabs is basically a syntax error.
- giancarlostoro 7y agoWhich is why PEP-8 the Python code style guide enforces 4 spaces. This maintains consistency throughout the community. Also PyCharm one of the more popular IDEs for Python uses 4 spaces by default.
- joepie91_ 7y agoThat's not what PEP-8 is for, it was meant to define the style of the standard libraries. A lot of people in the community voluntarily adopted it for their projects, but that wasn't its purpose.
- saagarjha 7y agoRight, but this doesn't mean that the author can't use tabs to indent their code.
- GrumpyNl 7y agoUse PhPStorm, alt f6