diff options
author | Alexey Kreshchuk <akrsch@gmail.com> | 2021-01-08 17:24:06 +0300 |
---|---|---|
committer | Alexey Kreshchuk <akrsch@gmail.com> | 2021-02-02 17:34:59 +0300 |
commit | cc67bc0541761fb857ed58ed3c9adbf7ee1b1a9b (patch) | |
tree | a5c3c6c1b57de4d942c26995b090387f3b54723c /ale_linters/php | |
parent | 9b5c09047361f3ec2cf18afbb6d1e03047a59778 (diff) | |
download | ale-cc67bc0541761fb857ed58ed3c9adbf7ee1b1a9b.zip |
add filename to output
Diffstat (limited to 'ale_linters/php')
-rw-r--r-- | ale_linters/php/phan.vim | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/ale_linters/php/phan.vim b/ale_linters/php/phan.vim index 53cb1ea9..50c6d6e6 100644 --- a/ale_linters/php/phan.vim +++ b/ale_linters/php/phan.vim @@ -39,7 +39,7 @@ function! ale_linters#php#phan#Handle(buffer, lines) abort let l:pattern = '^Phan error: \(\w\+\): \(.\+\) in \(.\+\) on line \(\d\+\)$' else " /path/to/some-filename.php:18 ERRORTYPE message - let l:pattern = '^.*:\(\d\+\)\s\(\w\+\)\s\(.\+\)$' + let l:pattern = '^\(.*\):\(\d\+\)\s\(\w\+\)\s\(.\+\)$' endif let l:output = [] @@ -49,13 +49,15 @@ function! ale_linters#php#phan#Handle(buffer, lines) abort let l:dict = { \ 'lnum': l:match[4] + 0, \ 'text': l:match[2], + \ 'filename': l:match[3], \ 'type': 'W', \} else let l:dict = { - \ 'lnum': l:match[1] + 0, - \ 'text': l:match[3], + \ 'lnum': l:match[2] + 0, + \ 'text': l:match[4], \ 'type': 'W', + \ 'filename': l:match[1], \} endif |