r372760 - [clang-format] [PR36858] Add missing .hh and .cs extensions from python support utilities
Paul Hoad via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 24 07:00:06 PDT 2019
Author: paulhoad
Date: Tue Sep 24 07:00:06 2019
New Revision: 372760
URL: http://llvm.org/viewvc/llvm-project?rev=372760&view=rev
Log:
[clang-format] [PR36858] Add missing .hh and .cs extensions from python support utilities
Summary: https://bugs.llvm.org/show_bug.cgi?id=36858 identifies .hh as a missing C++ header extension file while making this change I realized there was no support for .cs files which were added recently
Reviewers: pseyfert, klimek, owenpan
Reviewed By: klimek
Subscribers: cfe-commits
Tags: #clang-tools-extra, #clang
Differential Revision: https://reviews.llvm.org/D67949
Modified:
cfe/trunk/tools/clang-format/clang-format-diff.py
cfe/trunk/tools/clang-format/git-clang-format
Modified: cfe/trunk/tools/clang-format/clang-format-diff.py
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/clang-format/clang-format-diff.py?rev=372760&r1=372759&r2=372760&view=diff
==============================================================================
--- cfe/trunk/tools/clang-format/clang-format-diff.py (original)
+++ cfe/trunk/tools/clang-format/clang-format-diff.py Tue Sep 24 07:00:06 2019
@@ -43,8 +43,8 @@ def main():
help='custom pattern selecting file paths to reformat '
'(case sensitive, overrides -iregex)')
parser.add_argument('-iregex', metavar='PATTERN', default=
- r'.*\.(cpp|cc|c\+\+|cxx|c|cl|h|hpp|m|mm|inc|js|ts|proto'
- r'|protodevel|java)',
+ r'.*\.(cpp|cc|c\+\+|cxx|c|cl|h|hh|hpp|m|mm|inc|js|ts|proto'
+ r'|protodevel|java|cs)',
help='custom pattern selecting file paths to reformat '
'(case insensitive, overridden by -regex)')
parser.add_argument('-sort-includes', action='store_true', default=False,
Modified: cfe/trunk/tools/clang-format/git-clang-format
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/clang-format/git-clang-format?rev=372760&r1=372759&r2=372760&view=diff
==============================================================================
--- cfe/trunk/tools/clang-format/git-clang-format (original)
+++ cfe/trunk/tools/clang-format/git-clang-format Tue Sep 24 07:00:06 2019
@@ -77,13 +77,14 @@ def main():
'c', 'h', # C
'm', # ObjC
'mm', # ObjC++
- 'cc', 'cp', 'cpp', 'c++', 'cxx', 'hpp', 'hxx', # C++
+ 'cc', 'cp', 'cpp', 'c++', 'cxx', 'hh', 'hpp', 'hxx', # C++
'cu', # CUDA
# Other languages that clang-format supports
'proto', 'protodevel', # Protocol Buffers
'java', # Java
'js', # JavaScript
'ts', # TypeScript
+ 'cs', # C Sharp
])
p = argparse.ArgumentParser(
More information about the cfe-commits
mailing list