[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#38083: 27.0.50; Deprecation warnings in NS build
From: |
Po Lu |
Subject: |
bug#38083: 27.0.50; Deprecation warnings in NS build |
Date: |
Sat, 21 May 2022 19:50:29 +0800 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) |
Lars Ingebrigtsen <larsi@gnus.org> writes:
> I rooted out my Apple laptop (Macos 12.3.1, which is probably the
> newest?), and I get the following warnings:
>
> xwidget.c:491:19: warning: variable 'xw' set but not used
> [-Wunused-but-set-variable]
> struct xwidget *xw;
> ^
> xwidget.c:493:23: warning: unused variable 'keycode' [-Wunused-variable]
> int character = -1, keycode = -1;
> ^
> xwidget.c:492:17: warning: variable 'f' set but not used
> [-Wunused-but-set-variable]
> struct frame *f = NULL;
> ^
> xwidget.c:493:7: warning: unused variable 'character' [-Wunused-variable]
> int character = -1, keycode = -1;
> ^
> xwidget.c:494:7: warning: unused variable 'modifiers' [-Wunused-variable]
> int modifiers = 0;
> ^
The NS xwidget implementation is currently completely broken. I wrote
that in etc/TODO, and patches are welcome, since I don't know my way
around the Mac OS WebKit APIs.
> nsfns.m:841:47: warning: 'iconForFileType:' is deprecated: first deprecated
> in macOS 12.0 - Use -[NSWorkspace iconForContentType:] instead.
> [-Wdeprecated-declarations]
> image = [[[NSWorkspace sharedWorkspace] iconForFileType: @"text"]
> retain];
> ^
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSWorkspace.h:456:1:
> note: 'iconForFileType:' has been explicitly marked deprecated here
> - (NSImage *)iconForFileType:(NSString *)fileType API_DEPRECATED("Use
> -[NSWorkspace iconForContentType:] instead.", macos(10.0, 12.0));
> ^
> nsfns.m:1760:12: warning: 'setAllowedFileTypes:' is deprecated: first
> deprecated in macOS 12.0 - Use -allowedContentTypes instead
> [-Wdeprecated-declarations]
> [panel setAllowedFileTypes: nil];
> ^
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSSavePanel.h:215:49:
> note: property 'allowedFileTypes' is declared deprecated here
> @property (nullable, copy) NSArray<NSString *> *allowedFileTypes
> API_DEPRECATED("Use -allowedContentTypes instead", macos(10.3,12.0));
> ^
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSSavePanel.h:215:49:
> note: 'setAllowedFileTypes:' has been explicitly marked deprecated here
> nsfns.m:2599:11: warning: 'IOMasterPort' is deprecated: first deprecated in
> macOS 12.0 [-Wdeprecated-declarations]
> if (IOMasterPort (MACH_PORT_NULL, &masterPort) != kIOReturnSuccess
> ^~~~~~~~~~~~
> IOMainPort
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h:132:1:
> note: 'IOMasterPort' has been explicitly marked deprecated here
> IOMasterPort( mach_port_t bootstrapPort,
> ^
> CC lastfile.o
> 3 warnings generated.
I will look into the others, thanks.