Mercurial > vim
view src/testdir/sautest/autoload/foo.vim @ 25057:ffc3e1164652 v8.2.3065
patch 8.2.3065: Vim9: error when sourcing script twice and reusing function
Commit: https://github.com/vim/vim/commit/577dc93da9ec78684576bff71328d40f24bd6dd8
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Jun 27 15:35:40 2021 +0200
patch 8.2.3065: Vim9: error when sourcing script twice and reusing function
Problem: Vim9: error when sourcing script twice and reusing a function
name.
Solution: Check if the function is dead. (closes #8463)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 27 Jun 2021 15:45:03 +0200 |
parents | 9ffec4eb8d33 |
children | 6e1b0c4ab668 |
line wrap: on
line source
let g:loaded_foo_vim += 1 let foo#bar = {} func foo#bar.echo() let g:called_foo_bar_echo += 1 endfunc func foo#addFoo(head) return a:head .. 'foo' endfunc