“inconsistent use of tabs and spaces in indentation”

Don’t use tabs.

  1. Set your editor to use 4 spaces for indentation.
  2. Make a search and replace to replace all tabs with 4 spaces.
  3. Make sure your editor is set to display tabs as 8 spaces.

Note: The reason for 8 spaces for tabs is so that you immediately notice when tabs have been inserted unintentionally – such as when copying and pasting from example code that uses tabs instead of spaces.

Leave a Comment