Skip to content

Commit 900bb31

Browse files
authored
[clang-format][NFC] Use prog in clang-format-diff.py (#74399)
This is a minor improvement to #73491.
1 parent 1d89478 commit 900bb31

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

clang/tools/clang-format/clang-format-diff.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@
2525

2626
import argparse
2727
import difflib
28-
import os
2928
import re
3029
import subprocess
3130
import sys
@@ -37,9 +36,8 @@
3736

3837

3938
def main():
40-
basename = os.path.basename(sys.argv[0])
4139
parser = argparse.ArgumentParser(
42-
description=__doc__.format(clang_format_diff=basename),
40+
description=__doc__.format(clang_format_diff="%(prog)s"),
4341
formatter_class=argparse.RawDescriptionHelpFormatter,
4442
)
4543
parser.add_argument(

0 commit comments

Comments
 (0)