Replace all WebKit Library Version checks in WK2 with SDK version checks This is a followup to https://bugs.webkit.org/show_bug.cgi?id=168056 We can completely rely on SDK version checks - even for unreleased SDKs - By giving all of our tools a secret way to always pass linkedOnOrAfter checks.
Created attachment 301170 [details] Patch
Attachment 301170 [details] did not pass style-queue: ERROR: Tools/TestWebKitAPI/mac/mainMac.mm:43: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Tools/TestWebKitAPI/mac/mainMac.mm:44: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Source/WebKit2/UIProcess/Cocoa/VersionChecks.mm:39: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Source/WebKit2/UIProcess/Cocoa/VersionChecks.mm:40: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Source/WebKit2/UIProcess/Cocoa/VersionChecks.mm:41: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Tools/TestWebKitAPI/ios/mainIOS.mm:41: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Tools/TestWebKitAPI/ios/mainIOS.mm:42: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 7 in 13 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 301170 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=301170&action=review r=me What could possibly go wrong? :P > Source/WebKit2/ChangeLog:10 > + To allow our tools to still be able to adopt new behaviors even when built against older SDKs, s/adopt/test/ > Source/WebKit2/UIProcess/Cocoa/VersionChecks.mm:42 > + // Always make new behaviors work in Safari. The code is pretty clear at explaining how it achieves this behavior, but I'm not sure why we want it. Would be nice for this comment to explain why we want this behavior.
https://trac.webkit.org/changeset/212134
Comment on attachment 301170 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=301170&action=review > Source/WebKit2/UIProcess/Cocoa/VersionChecks.h:-65 > - static const uint32_t SDKVersion { DYLD_MACOSX_VERSION_10_12_4 }; This existing code looks wrong to me, we shouldn't change behavior for native clients other than in major updates. How did this get in? We should probably get this corrected soon.
(In reply to comment #5) > Comment on attachment 301170 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=301170&action=review > > > Source/WebKit2/UIProcess/Cocoa/VersionChecks.h:-65 > > - static const uint32_t SDKVersion { DYLD_MACOSX_VERSION_10_12_4 }; > > This existing code looks wrong to me, we shouldn't change behavior for > native clients other than in major updates. Why not? > How did this get in? Because I put it in because multiple people think it's right. > We should probably get this corrected soon. The first thing that would have to happen is to establish that something is incorrect, which I'm not sure we have done.
(In reply to comment #6) > (In reply to comment #5) > > > How did this get in? > > Because I put it in because multiple people think it's right. And also, it had already be in - in practice - with the WebKit Library Version check.
(In reply to comment #7) > (In reply to comment #6) > > (In reply to comment #5) > > > > > How did this get in? > > > > Because I put it in because multiple people think it's right. > > And also, it had already be in - in practice - with the WebKit Library > Version check. To link to that: https://trac.webkit.org/changeset/210031
Followed up: https://trac.webkit.org/changeset/212256