code: def parse_options(arguments=None):
      
      if arguments is None:
          arguments = sys.argv[1:]
      if isinstance(arguments, str):
          arguments = arguments.split()
      if isinstance(arguments, argparse.Namespace):
          return arguments
      parser = create_args_parser()
      args = parser.parse_args(arguments)
      # pprint(args.__dict__)
  
      args.dialect = args.dialect.lower()
      if args.dialect not in ['lisp', 'newlisp', 'clojure', 'scheme', 'all', '']:
          parser.error("`{0}' is not a recognized dialect".format(args.dialect))
  
      args.backup_dir = os.path.expanduser(args.backup_dir)
      if not os.path.exists(args.backup_dir):
          parser.error("Directory `{0}' does not exist".format(args.backup_dir))
  
      if len(args.files) > 1 and args.output_file:
          parser.error('Cannot use the -o flag when more than one file is specified')
  
      if not args.files:
          # Indentation from standard input
          if args.modify and not args.output_file:
              args.modify = False
          args.backup = False
          args.warning = False
  
      if args.output_diff:
          # If someone requests a diff we assume he/she doesn't want the file to be
          # modified
          args.modify = False
  
      return args
docs: Reads command-line arguments
  
      >>> parse_options('--indent-comments')