patch 9.1.1897: Mac: Build failure on Mac OS X 10.6

Commit: 
https://github.com/vim/vim/commit/24e4fa1603ff30d814c08a3516b092f012067732
Author: Luke Lollard <[email protected]>
Date:   Thu Nov 6 20:04:38 2025 +0000

    patch 9.1.1897: Mac: Build failure on Mac OS X 10.6
    
    Problem:  Mac: Build failure on Mac OS X 10.6 due to the use of generics
              for the sound feature.
    Solution: Use the simple, non-generic Objective-C version.
              (Luke Lollard)
    
    fixes: #17678
    closes: #18681
    
    Co-authored-by: Yee Cheng Chin <[email protected]>
    Signed-off-by: Luke Lollard <[email protected]>
    Signed-off-by: Christian Brabandt <[email protected]>

diff --git a/src/os_macosx.m b/src/os_macosx.m
index 153c2f190..1a633b9d6 100644
--- a/src/os_macosx.m
+++ b/src/os_macosx.m
@@ -386,7 +386,7 @@ timer_delete(timer_t timerid)
 
 #ifdef FEAT_SOUND
 
-static NSMutableDictionary<NSNumber*, NSSound*> *sounds_list = nil;
+static NSMutableDictionary *sounds_list = nil;
 
 /// A delegate for handling when a sound has stopped playing, in
 /// order to clean up the sound and to send a callback.
@@ -463,9 +463,9 @@ sound_mch_play(const char_u* sound_name, long sound_id, 
soundcb_T *callback, boo
 
        if (sounds_list == nil)
        {
-           sounds_list = [[NSMutableDictionary<NSNumber*, NSSound*> alloc] 
init];
+           sounds_list = [[NSMutableDictionary alloc] init];
        }
-       sounds_list[[NSNumber numberWithLong:sound_id]] = sound;
+       [sounds_list setObject:sound forKey:[NSNumber numberWithLong:sound_id]];
 
        // Make a delegate to handle when the sound stops. No need to call
        // autorelease because NSSound only holds a weak reference to it.
@@ -482,7 +482,7 @@ sound_mch_stop(long sound_id)
 {
     @autoreleasepool
     {
-       NSSound *sound = sounds_list[[NSNumber numberWithLong:sound_id]];
+       NSSound *sound = [sounds_list objectForKey:[NSNumber 
numberWithLong:sound_id]];
        if (sound != nil)
        {
            // Stop the sound. No need to release it because the delegate will 
do
diff --git a/src/version.c b/src/version.c
index ba48dda5a..f69be10d2 100644
--- a/src/version.c
+++ b/src/version.c
@@ -729,6 +729,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1897,
 /**/
     1896,
 /**/

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/vim_dev/E1vJWOl-001D4p-RV%40256bit.org.

Raspunde prin e-mail lui