Merge pull request #3390 from benknoble/fix-dafny-filename

dafny: include correct filename in lint results
This commit is contained in:
Horacio Sanson 2021-01-06 11:19:29 +09:00 committed by GitHub
commit 4c454c96a9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -6,7 +6,7 @@ function! ale_linters#dafny#dafny#Handle(buffer, lines) abort
for l:match in ale#util#GetMatches(a:lines, l:pattern)
call add(l:output, {
\ 'bufnr': a:buffer,
\ 'filename': l:match[1],
\ 'col': l:match[3] + 0,
\ 'lnum': l:match[2] + 0,
\ 'text': l:match[5],

View File

@ -8,14 +8,14 @@ Execute(The Dafny handler should parse output correctly):
AssertEqual
\ [
\ {
\ 'bufnr': 0,
\ 'filename': 'File.dfy',
\ 'col': 45,
\ 'lnum': 123,
\ 'text': 'A precondition for this call might not hold.',
\ 'type': 'E'
\ },
\ {
\ 'bufnr': 0,
\ 'filename': 'File.dfy',
\ 'col': 90,
\ 'lnum': 678,
\ 'text': 'This is the precondition that might not hold.',