Patch 8.2.2300
Problem: Vim9: wrong order on type stack when using dict.
Solution: Generate constants before a dict. (closes #7619)
Files: src/vim9compile.c, src/testdir/test_vim9_expr.vim
*** ../vim-8.2.2299/src/vim9compile.c 2021-01-04 16:15:55.066084896 +0100
--- src/vim9compile.c 2021-01-04 17:34:55.359304068 +0100
***************
*** 3027,3032 ****
--- 3027,3034 ----
if (d == NULL)
return FAIL;
+ if (generate_ppconst(cctx, ppconst) == FAIL)
+ return FAIL;
for (;;)
{
char_u *key = NULL;
*** ../vim-8.2.2299/src/testdir/test_vim9_expr.vim 2021-01-03
21:53:28.279020545 +0100
--- src/testdir/test_vim9_expr.vim 2021-01-04 17:34:20.567409438 +0100
***************
*** 1094,1099 ****
--- 1094,1101 ----
$ENVVAR = 'env'
assert_equal('aenv', 'a' .. $ENVVAR)
+
+ assert_equal('val', '' .. {key: 'val'}['key'])
END
CheckDefAndScriptSuccess(lines)
enddef
*** ../vim-8.2.2299/src/version.c 2021-01-04 16:15:55.066084896 +0100
--- src/version.c 2021-01-04 17:33:17.031600786 +0100
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 2300,
/**/
--
I AM THANKFUL...
...for the mess to clean after a party because it means I have
been surrounded by friends.
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ 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/202101041641.104GfNCD2489625%40masaka.moolenaar.net.