-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #467 from adriaanzon/php-fix-double-errors
PHP: Fix double errors and support fatal errors
- Loading branch information
Showing
2 changed files
with
12 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
" Author: Spencer Wood <https://github.com/scwood> | ||
" Author: Spencer Wood <https://github.com/scwood>, Adriaan Zonnenberg <[email protected]> | ||
" Description: This file adds support for checking PHP with php-cli | ||
|
||
function! ale_linters#php#php#Handle(buffer, lines) abort | ||
" Matches patterns like the following: | ||
" | ||
" PHP Parse error: syntax error, unexpected ';', expecting ']' in - on line 15 | ||
let l:pattern = '\vParse error:\s+(.+unexpected ''(.+)%(expecting.+)@<!''.*|.+) in - on line (\d+)' | ||
let l:pattern = '\vPHP %(Fatal|Parse) error:\s+(.+unexpected ''(.+)%(expecting.+)@<!''.*|.+) in - on line (\d+)' | ||
|
||
let l:output = [] | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters