Skip to content

Commit fc83b28

Browse files
qqaatwNicolasHugpmeier
authored
Add objc clang format (pytorch#7677)
Co-authored-by: Nicolas Hug <contact@nicolas-hug.com> Co-authored-by: Philip Meier <github.pmeier@posteo.de>
1 parent b9a1984 commit fc83b28

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

.clang-format

+7-3
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,6 @@ MacroBlockBegin: ''
6060
MacroBlockEnd: ''
6161
MaxEmptyLinesToKeep: 1
6262
NamespaceIndentation: None
63-
ObjCBlockIndentWidth: 2
64-
ObjCSpaceAfterProperty: false
65-
ObjCSpaceBeforeProtocolList: false
6663
PenaltyBreakBeforeFirstCallParameter: 1
6764
PenaltyBreakComment: 300
6865
PenaltyBreakFirstLessLess: 120
@@ -85,4 +82,11 @@ SpacesInSquareBrackets: false
8582
Standard: Cpp11
8683
TabWidth: 8
8784
UseTab: Never
85+
---
86+
Language: ObjC
87+
ColumnLimit: 120
88+
AlignAfterOpenBracket: Align
89+
ObjCBlockIndentWidth: 2
90+
ObjCSpaceAfterProperty: false
91+
ObjCSpaceBeforeProtocolList: false
8892
...

.pre-commit-config.yaml

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ repos:
66
- id: check-toml
77
- id: check-yaml
88
exclude: packaging/.*
9+
args:
10+
- --allow-multiple-documents
911
- id: mixed-line-ending
1012
args: [--fix=lf]
1113
- id: end-of-file-fixer

0 commit comments

Comments
 (0)