Bug 240478

Summary: check-webkit-style: validate enums declared with explicit type
Product: WebKit Reporter: Yury Semikhatsky <yurys>
Component: Tools / TestsAssignee: Yury Semikhatsky <yurys>
Status: RESOLVED FIXED    
Severity: Normal CC: ews-watchlist, glenn, hi, jbedard, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch hi: review+

Description Yury Semikhatsky 2022-05-16 14:09:52 PDT
check-webkit-style: validate enums declared with explicit type
Comment 1 Yury Semikhatsky 2022-05-16 14:12:10 PDT
Created attachment 459453 [details]
Patch
Comment 2 Yury Semikhatsky 2022-05-16 14:12:58 PDT
This was discovered while looking at the style bot failures inhttps://bugs.webkit.org/show_bug.cgi?id=240326
Comment 3 Devin Rousso 2022-05-17 12:16:30 PDT
Comment on attachment 459453 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=459453&action=review

rs=mews

> Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py:4396
> +            '''enum class Type : uint8_t { FIRST, SECOND };''',

i'd include some valid test cases too (e.g. `enum class Foo : uint8_t { First, Second }`)
Comment 4 Yury Semikhatsky 2022-05-17 13:31:10 PDT
Pull request: https://github.com/WebKit/WebKit/pull/688
Comment 5 Yury Semikhatsky 2022-05-17 13:32:08 PDT
Comment on attachment 459453 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=459453&action=review

>> Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py:4396
>> +            '''enum class Type : uint8_t { FIRST, SECOND };''',
> 
> i'd include some valid test cases too (e.g. `enum class Foo : uint8_t { First, Second }`)

Done.
Comment 6 EWS 2022-05-17 15:01:38 PDT
Committed r294351 (250659@main): <https://commits.webkit.org/250659@main>

Reviewed commits have been landed. Closing PR #688 and removing active labels.
Comment 7 Radar WebKit Bug Importer 2022-05-17 15:02:13 PDT
<rdar://problem/93455377>