0

Given the code:

def main(args=None):
    if args is None:
        args = sys.argv[1:]
    load_data()

Calling indent-region on the code (under python mode), the output would be:

def main(args=None):
    if args is None:
        args = sys.argv[1:]
        load_data()

load_data is unexpectedly indented.

2
  • What is indent-region supposed to do in a language where indentation is meaningful? Nov 22, 2020 at 13:13
  • At least it shall not do something unexpected. indent-region invokes python-indent-region. It is more about python-indent-region not working, not about indent-region.
    – FunkyBaby
    Nov 22, 2020 at 14:12

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.