Patch 9.0.0355
Problem:    Check for uppercase char in autoload name is wrong, it checks the
            name of the script.
Solution:   Remove the check. (closes #11031)
Files:      src/evalvars.c, src/testdir/test_let.vim


*** ../vim-9.0.0354/src/evalvars.c      2022-08-24 16:30:30.686752454 +0100
--- src/evalvars.c      2022-09-02 11:16:47.674457821 +0100
***************
*** 4012,4021 ****
  {
      // Allow for w: b: s: and t:.  In Vim9 script s: is not allowed, because
      // the name can be used without the s: prefix.
      if (!((vim_strchr((char_u *)"wbt", name[0]) != NULL
                    || (!in_vim9script() && name[0] == 's')) && name[1] == ':')
            && !ASCII_ISUPPER((name[0] != NUL && name[1] == ':')
!                                                    ? name[2] : name[0]))
      {
        semsg(_(e_funcref_variable_name_must_start_with_capital_str), name);
        return TRUE;
--- 4012,4023 ----
  {
      // Allow for w: b: s: and t:.  In Vim9 script s: is not allowed, because
      // the name can be used without the s: prefix.
+     // Allow autoload variable.
      if (!((vim_strchr((char_u *)"wbt", name[0]) != NULL
                    || (!in_vim9script() && name[0] == 's')) && name[1] == ':')
            && !ASCII_ISUPPER((name[0] != NUL && name[1] == ':')
!                                                    ? name[2] : name[0])
!           && vim_strchr(name, '#') == NULL)
      {
        semsg(_(e_funcref_variable_name_must_start_with_capital_str), name);
        return TRUE;
*** ../vim-9.0.0354/src/testdir/test_let.vim    2022-05-10 13:12:25.000000000 
+0100
--- src/testdir/test_let.vim    2022-09-02 11:16:47.674457821 +0100
***************
*** 8,13 ****
--- 8,17 ----
    let Test104#numvar = function('tr')
    call assert_equal("function('tr')", string(Test104#numvar))
  
+   let foo#tr = function('tr')
+   call assert_equal("function('tr')", string(foo#tr))
+   unlet foo#tr
+ 
    let a = 1
    let b = 2
  
*** ../vim-9.0.0354/src/version.c       2022-09-01 18:42:29.680258960 +0100
--- src/version.c       2022-09-02 11:21:01.238287625 +0100
***************
*** 709,710 ****
--- 709,712 ----
  {   /* Add new patch number below this line */
+ /**/
+     355,
  /**/

-- 
ALL:   A witch!  A witch!
WITCH: It's a fair cop.
ALL:   Burn her!  Burn her!  Let's make her into a ladder.
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///                                                                      \\\
\\\        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
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 on the web visit 
https://groups.google.com/d/msgid/vim_dev/20220902102604.3584E1C0A26%40moolenaar.net.

Raspunde prin e-mail lui