diff options
Diffstat (limited to 'src/testdir/test_vim9_script.vim')
-rw-r--r-- | src/testdir/test_vim9_script.vim | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/src/testdir/test_vim9_script.vim b/src/testdir/test_vim9_script.vim index 0602b2ae5b..10f41c7bf8 100644 --- a/src/testdir/test_vim9_script.vim +++ b/src/testdir/test_vim9_script.vim @@ -4177,19 +4177,29 @@ def Test_xxx_echoerr_line_number() CheckDefExecAndScriptFailure(lines, 'some error continued', 1) enddef -def ProfiledFunc() +def ProfiledWithLambda() var n = 3 echo [[1, 2], [3, 4]]->filter((_, l) => l[0] == n) enddef +def ProfiledNested() + var x = 0 + def Nested(): any + return x + enddef + Nested() +enddef + " Execute this near the end, profiling doesn't stop until Vim exists. " This only tests that it works, not the profiling output. def Test_xx_profile_with_lambda() CheckFeature profile profile start Xprofile.log - profile func ProfiledFunc - ProfiledFunc() + profile func ProfiledWithLambda + ProfiledWithLambda() + profile func ProfiledNested + ProfiledNested() enddef " Keep this last, it messes up highlighting. |