Bug 234655

Summary: clang-format: Set SpaceAfterTemplateKeyword false
Product: WebKit Reporter: Fujii Hironori <Hironori.Fujii>
Component: New BugsAssignee: Fujii Hironori <Hironori.Fujii>
Status: RESOLVED FIXED    
Severity: Normal CC: don.olmstead, heycam, kkinnunen, ross.kirsling, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=183302
Attachments:
Description Flags
Patch don.olmstead: review+

Description Fujii Hironori 2021-12-23 16:41:26 PST
clang-format: Set SpaceAfterTemplateKeyword false

Bug 183302 added the folowing setting to .clang-format.

> SpaceAfterTemplateKeyword: true

However, no space seems more commmon style.

$ find Source/{WTF,WebCore,WebKitLegacy,WebKit} -name "*.cpp" -exec grep "template<" "{}" \+ | wc -l
1312
$ find Source/{WTF,WebCore,WebKitLegacy,WebKit} -name "*.cpp" -exec grep "template <" "{}" \+ | wc -l
318
Comment 1 Fujii Hironori 2021-12-23 16:49:05 PST
Created attachment 447919 [details]
Patch
Comment 2 Fujii Hironori 2021-12-26 13:09:53 PST
grepping *.cpp and *.h:

$ find Source/{WTF,WebCore,WebKitLegacy,WebKit} -name "*.cpp" -o -name "*.h" -exec grep "template<" "{}" \+ | wc -l
7913
$ find Source/{WTF,WebCore,WebKitLegacy,WebKit} -name "*.cpp" -o -name "*.h" -exec grep "template <" "{}" \+ | wc -l
1385
Comment 3 Radar WebKit Bug Importer 2021-12-30 16:42:17 PST
<rdar://problem/87019846>
Comment 4 Fujii Hironori 2022-01-04 12:59:47 PST
Committed r287581 (245710@trunk): <https://commits.webkit.org/245710@trunk>