From f323d3cc74b2b612c5b7781bf367e12114a92c8c Mon Sep 17 00:00:00 2001 From: cheater Date: Wed, 8 Feb 2012 07:48:02 +0100 Subject: [PATCH] Starting refactor towards an iterator. --- plugin/pythonhelper.vim | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugin/pythonhelper.vim b/plugin/pythonhelper.vim index 6c2bc67..d8b6730 100644 --- a/plugin/pythonhelper.vim +++ b/plugin/pythonhelper.vim @@ -389,6 +389,9 @@ class SimplePythonTagsParser(object): # }}} +def vimBufferIterator(vimBuffer): + return VimReadlineBuffer(vimBuffer) + # class VimReadlineBuffer() {{{ class VimReadlineBuffer(object): # DOC {{{ @@ -508,7 +511,7 @@ def getTags(bufferNumber, changedTick): # }}} # get the tags {{{ - simpleTagsParser = SimplePythonTagsParser(VimReadlineBuffer(vim.current.buffer)) + simpleTagsParser = SimplePythonTagsParser(vimBufferIterator(vim.current.buffer)) tagLineNumbers, tags = simpleTagsParser.getTags() # }}}