From 71cc1b12cd2a92ceadff5cef73dcef387374ce36 Mon Sep 17 00:00:00 2001 From: bennyyip Date: Tue, 24 Feb 2026 21:13:40 +0000 Subject: [PATCH] patch 9.2.0048: MS-Windows: ConPTY not yet preferred Problem: MS-Windows: ConPTY not yet preferred Solution: Mark ConPTY as stable starting with Windows 11 (build 22000). Vim will now prefer ConPTY over winpty on these systems. fixes: #19033 closes: #19037 Signed-off-by: bennyyip Signed-off-by: Christian Brabandt --- runtime/doc/options.txt | 6 +++--- runtime/doc/terminal.txt | 6 +++--- runtime/doc/version9.txt | 5 +++-- src/os_win32.c | 6 +++--- src/version.c | 2 ++ 5 files changed, 14 insertions(+), 11 deletions(-) diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 0798934c2d..a264127822 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -1,4 +1,4 @@ -*options.txt* For Vim version 9.2. Last change: 2026 Feb 21 +*options.txt* For Vim version 9.2. Last change: 2026 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -9120,8 +9120,8 @@ A jump table for the options with a short description can be found at |Q_op|. |ConPTY| support depends on the platform. Windows 10 October 2018 Update is the first version that supports ConPTY, however it is still - considered unstable. ConPTY might become stable in the next release - of Windows 10. winpty support needs to be installed. If neither is + considered unstable. ConPTY has become stable with the initial release + of Windows 11. winpty support needs to be installed. If neither is supported then you cannot open a terminal window. *'terse'* *'noterse'* diff --git a/runtime/doc/terminal.txt b/runtime/doc/terminal.txt index c86fb207e4..4a2c4710cd 100644 --- a/runtime/doc/terminal.txt +++ b/runtime/doc/terminal.txt @@ -1,4 +1,4 @@ -*terminal.txt* For Vim version 9.2. Last change: 2026 Feb 14 +*terminal.txt* For Vim version 9.2. Last change: 2026 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -490,8 +490,8 @@ On more recent versions of MS-Windows 10 (beginning with the "October 2018 Update"), winpty is no longer required. On those versions, |:terminal| will use Windows' built-in support for hosting terminal applications, "ConPTY". When ConPTY is in use, there may be rendering artifacts regarding ambiguous-width -characters. If you encounter any such issues, install "winpty". Until the -ConPTY problems have been fixed "winpty" will be preferred. +characters. If you encounter any such issues, install "winpty". ConPTY +support is considered stable with the first release of Windows 11. Environment variables are used to pass information to the running job: VIM_SERVERNAME v:servername diff --git a/runtime/doc/version9.txt b/runtime/doc/version9.txt index bd93f1bb36..5c35f3a845 100644 --- a/runtime/doc/version9.txt +++ b/runtime/doc/version9.txt @@ -1,4 +1,4 @@ -*version9.txt* For Vim version 9.2. Last change: 2026 Feb 16 +*version9.txt* For Vim version 9.2. Last change: 2026 Feb 24 VIM REFERENCE MANUAL by Bram Moolenaar @@ -52588,7 +52588,8 @@ Popups ~ Other ~ ----- -The new |xdg.vim| script for full XDG compatibility is included +- The new |xdg.vim| script for full XDG compatibility is included. +- |ConPTY| support is considered stable as of Windows 11. *changed-9.3* Changed~ diff --git a/src/os_win32.c b/src/os_win32.c index a3d66c4b9c..edaf7cb306 100644 --- a/src/os_win32.c +++ b/src/os_win32.c @@ -8565,11 +8565,11 @@ mch_setenv(char *var, char *value, int x UNUSED) #define CONPTY_INSIDER_BUILD MAKE_VER(10, 0, 18995) /* - * Not stable now. + * Make conpty default on Windows 11 */ -#define CONPTY_STABLE_BUILD MAKE_VER(10, 0, 32767) // T.B.D. +#define CONPTY_STABLE_BUILD MAKE_VER(10, 0, 22000) // Notes: -// Win 10 22H2 Final is build 19045, it's conpty is widely used. +// Win 10 22H2 Final is build 19045, its conpty is widely used. // Strangely, 19045 is newer but is a lower build number than the 2020 insider // preview which had a build 19587. And, not sure how stable that was? // Win Server 2022 (May 10, 2022) is build 20348, its conpty is widely used. diff --git a/src/version.c b/src/version.c index ceab876163..478b9f1bc7 100644 --- a/src/version.c +++ b/src/version.c @@ -734,6 +734,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 48, /**/ 47, /**/ -- 2.47.3