Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 5584d6ed33e038555ea89d301a610a6b042f4c3d
https://github.com/WebKit/WebKit/commit/5584d6ed33e038555ea89d301a610a6b042f4c3d
Author: Wenson Hsieh <[email protected]>
Date: 2025-05-17 (Sat, 17 May 2025)
Changed paths:
M Source/WebCore/PAL/pal/spi/ios/UIKitSPI.h
Log Message:
-----------
Unreviewed, try to fix the Mac Catalyst build
rdar://151519087
Reviewed by Chris Dumez.
Speculative fix for a build failure in rdar://151519087 — make sure that the
declaration of
`UIDocumentInteractionController` is pulled in when importing `UIKitSPI.h` in
WebCore. From the
build failure, it seems the return type of
`allocUIDocumentInteractionControllerInstance()` is
treated as an `id` instead of `UIDocumentInteractionController *`, due to the
soft-linked class
being only a forward declaration.
```
<redacted>/Source/WebCore/rendering/ios/RenderThemeIOS.mm:1244:36: error:
'setName:' is unavailable: not available on macCatalyst
1244 | [documentInteractionController setName:fileName.isEmpty() ?
title.createNSString().get() : fileName.createNSString().get()];
| ^
In file included from
<redacted>/DerivedSources/WebCore/unified-sources/UnifiedSource55-mm.mm:2:
In file included from
<redacted>/Source/WebCore/rendering/cocoa/RenderThemeCocoa.mm:84:
In file included from PAL/pal/ios/UIKitSoftLink.h:30:
In file included from PAL/pal/spi/ios/UIKitSPI.h:44:
…
<redacted>.h:23:28: note: property 'name' is declared unavailable here
23 | @property (copy) NSString* name API_AVAILABLE(macos(10.13))
API_UNAVAILABLE(ios, tvos, watchos);
```
To (maybe) fix this, we pull `#import <UIKit/UIKit.h>` out to the start of
`UIKitSPI.h` to ensure
that all public headers (which includes the declaration of
`UIDocumentInteractionController`) get
pulled in when compiling `RenderThemeIOS.mm` (and anything else that imports
PAL's `UIKitSPI.h`).
* Source/WebCore/PAL/pal/spi/ios/UIKitSPI.h:
Canonical link: https://commits.webkit.org/295067@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes