Mercurial > vim
view runtime/tools/emoji_list.vim @ 25515:d84f6784c27c v8.2.3294
patch 8.2.3294: Lua: memory leak when adding dict item fails
Commit: https://github.com/vim/vim/commit/1b6acf02b7e685ecb87ccba52c91835a7519073e
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Aug 5 16:47:08 2021 +0200
patch 8.2.3294: Lua: memory leak when adding dict item fails
Problem: Lua: memory leak when adding dict item fails.
Solution: Free the typval and the dict item.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 05 Aug 2021 17:00:03 +0200 |
parents | 99ef85ff1af4 |
children |
line wrap: on
line source
" Script to fill the window with emoji characters, one per line. " Source this script: :source % if &modified new else enew endif " Use a compiled Vim9 function for speed def DoIt() var lnum = 1 for c in range(0x100, 0x1ffff) var cs = nr2char(c) if charclass(cs) == 3 setline(lnum, '|' .. cs .. '| ' .. strwidth(cs)) lnum += 1 endif endfor enddef call DoIt() set nomodified