Oct-18-2018, 10:07 PM
Quote:My way works very well.until some unknowing user tries to read your code and doesn't know that his editor has been set up with 20 character tabs.
Why interpreter accepts indentation made with spaces and not those by tabs
|
Oct-18-2018, 10:07 PM
Quote:My way works very well.until some unknowing user tries to read your code and doesn't know that his editor has been set up with 20 character tabs.
Oct-19-2018, 05:46 AM
On vim the default of the tab is 12, but you adjust with : :set softtabstop=4
Oct-19-2018, 08:29 AM
(Oct-18-2018, 06:12 PM)sylas Wrote: IMy way works very well.Two threads on this non-issue are an ample proof ![]()
Test everything in a Python shell (iPython, Azure Notebook, etc.)
Jan-10-2019, 11:17 PM
If you have a GUI environment, the Spyder3 IDE (https://github.com/spyder-ide/spyder) will catch mixes of spaces and tabs by flagging the first inconsistent line in every indented block. Also, the Source drop down from the menu has some very useful source file cleanup functions:
|
|