From b33e37470f2424241c21132159010ada09ce5346 Mon Sep 17 00:00:00 2001 From: LCD 47 Date: Wed, 6 Feb 2013 16:27:49 +0200 Subject: [PATCH] Output from pylint should be sorted. --- syntax_checkers/python/pylint.vim | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/syntax_checkers/python/pylint.vim b/syntax_checkers/python/pylint.vim index 1280ff1d..47f705c5 100644 --- a/syntax_checkers/python/pylint.vim +++ b/syntax_checkers/python/pylint.vim @@ -23,7 +23,11 @@ function! SyntaxCheckers_python_pylint_GetLocList() let n -= 1 endwhile - return loclist + return sort(loclist, 's:CmpLoclist') +endfunction + +function! s:CmpLoclist(a, b) + return a:a['lnum'] - a:b['lnum'] endfunction call g:SyntasticRegistry.CreateAndRegisterChecker({