patch 8.2.3378: MS-Windows: completing environment variables with % is wrong

Problem:    MS-Windows: completing environment variables with % is wrong.
Solution:   Only complete environment variables with $. (Albert Liu,
            closes #8791)
diff --git a/src/cmdexpand.c b/src/cmdexpand.c
index 27fda78..58ba759 100644
--- a/src/cmdexpand.c
+++ b/src/cmdexpand.c
@@ -1277,12 +1277,8 @@
 		xp->xp_context = EXPAND_SHELLCMD;
 	}
 
-	// Check for environment variable
-	if (*xp->xp_pattern == '$'
-#if defined(MSWIN)
-		|| *xp->xp_pattern == '%'
-#endif
-		)
+	// Check for environment variable.
+	if (*xp->xp_pattern == '$')
 	{
 	    for (p = xp->xp_pattern + 1; *p != NUL; ++p)
 		if (!vim_isIDc(*p))
@@ -1296,7 +1292,7 @@
 		    compl = EXPAND_ENV_VARS;
 	    }
 	}
-	// Check for user names
+	// Check for user names.
 	if (*xp->xp_pattern == '~')
 	{
 	    for (p = xp->xp_pattern + 1; *p != NUL && *p != '/'; ++p)
diff --git a/src/testdir/test_cmdline.vim b/src/testdir/test_cmdline.vim
index f7f55aa..0a71b11 100644
--- a/src/testdir/test_cmdline.vim
+++ b/src/testdir/test_cmdline.vim
@@ -9,6 +9,10 @@
   call writefile(['testfile'], 'Xtestfile')
   call feedkeys(":e Xtest\t\r", "tx")
   call assert_equal('testfile', getline(1))
+
+  " Pressing <Tab> after '%' completes the current file, also on MS-Windows
+  call feedkeys(":e %\t\r", "tx")
+  call assert_equal('e Xtestfile', @:)
   call delete('Xtestfile')
 endfunc
 
diff --git a/src/version.c b/src/version.c
index 7aa602f..a3f0a8d 100644
--- a/src/version.c
+++ b/src/version.c
@@ -756,6 +756,8 @@
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    3378,
+/**/
     3377,
 /**/
     3376,