[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/haskell-tng-mode 82312a2 126/385: working compilation matc
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/haskell-tng-mode 82312a2 126/385: working compilation matchers |
Date: |
Tue, 5 Oct 2021 23:59:15 -0400 (EDT) |
branch: elpa/haskell-tng-mode
commit 82312a246b07d425cb50943b2cc4bc02d4823e84
Author: Tseen She <ts33n.sh3@gmail.com>
Commit: Tseen She <ts33n.sh3@gmail.com>
working compilation matchers
---
haskell-tng-compile.el | 21 ++++++++++++++++++---
test/src/ghc-8.4.4-error.compile.faceup | 2 +-
test/src/ghc-8.4.4-errorspan.compile.faceup | 2 +-
test/src/ghc-8.4.4-warning.compile.faceup | 2 +-
test/src/ghc-8.4.4-warningspan.compile.faceup | 2 +-
test/src/hspec-failure.compile.faceup | 2 +-
6 files changed, 23 insertions(+), 8 deletions(-)
diff --git a/haskell-tng-compile.el b/haskell-tng-compile.el
index aa3d769..26afe98 100644
--- a/haskell-tng-compile.el
+++ b/haskell-tng-compile.el
@@ -17,10 +17,25 @@
;; TODO set compilation-directory when opening the file
;; TODO set compilation-environment to include TASTY envvars
-(defvar haskell-tng-compile-error-regexp-alist
+(defvar haskell-tng-compilation-error-regexp-alist
+ (let ((file '(: (group (+ any) ".hs")))
+ (num '(: (group (+ digit)))))
+ `(;; ghc errors / warnings (including -ferror-spans)
+ (,(rx-to-string `(: bol ,file ":" ,num ":" ,num (? "-" ,num) ": error:"))
+ 1 2 (3 . 4) 2 1)
+ (,(rx-to-string `(: bol ,file ":" ,num ":" ,num (? "-" ,num) ":
warning:"))
+ 1 2 (3 . 4) 1 1)
+ ;; FIXME multi-line error spans (and tests)
+
+ ;; hspec
+ (,(rx-to-string `(: bol (+ space) ,file ":" ,num ":" ,num ":"))
+ 1 2 3 2 1)
+ ;; tasty
+ (,(rx-to-string
+ `(: bol (+ space) "error, called at" (+ space) ,file ":" ,num ":"
,num " in "))
+ 1 2 3 2 1)
+ ))
"The `compilation-error-regexp-alist' for `haskell-tng'."
- ;; FIXME error-regexp-alist
- nil
)
(defvar haskell-tng-compile:history '("cabal v2-build -O0"))
diff --git a/test/src/ghc-8.4.4-error.compile.faceup
b/test/src/ghc-8.4.4-error.compile.faceup
index 030818c..1c9e51d 100644
--- a/test/src/ghc-8.4.4-error.compile.faceup
+++ b/test/src/ghc-8.4.4-error.compile.faceup
@@ -10,7 +10,7 @@ Building library for stackage-to-hackage-1.1.0..
[1 of 2] Compiling StackageToHackage.Stackage (
lib/StackageToHackage/Stackage.hs,
/home/tseenshe/stack2cabal/dist-newstyle/build/x86_64-linux/ghc-8.4.4/stackage-to-hackage-1.1.0/noopt/build/StackageToHackage/Stackage.o
)
[2 of 2] Compiling StackageToHackage.Hackage (
lib/StackageToHackage/Hackage.hs,
/home/tseenshe/stack2cabal/dist-newstyle/build/x86_64-linux/ghc-8.4.4/stackage-to-hackage-1.1.0/noopt/build/StackageToHackage/Hackage.o
)
-«U:«:compilation-error:lib/StackageToHackage/Hackage.hs»:«:compilation-line-number:33»:«:compilation-column-number:16»:»
error:
+«U:«:compilation-error:lib/StackageToHackage/Hackage.hs»»:«:compilation-line-number:33»:«:compilation-column-number:16»:
error:
parse error on input ‘=’
Perhaps you need a 'let' in a 'do' block?
e.g. 'let x = 5' instead of 'x = 5'
diff --git a/test/src/ghc-8.4.4-errorspan.compile.faceup
b/test/src/ghc-8.4.4-errorspan.compile.faceup
index aca64c8..a399f37 100644
--- a/test/src/ghc-8.4.4-errorspan.compile.faceup
+++ b/test/src/ghc-8.4.4-errorspan.compile.faceup
@@ -10,7 +10,7 @@ Building library for stackage-to-hackage-1.1.0..
[1 of 2] Compiling StackageToHackage.Stackage
[2 of 2] Compiling StackageToHackage.Hackage
-«U:«:compilation-error:lib/StackageToHackage/Hackage.hs»:«:compilation-line-number:35»:«:compilation-column-number:16»-«:compilation-column-number:18»:»
error:
+«U:«:compilation-error:lib/StackageToHackage/Hackage.hs»»:«:compilation-line-number:35»:«:compilation-column-number:16»-«:compilation-column-number:18»:
error:
parse error on input ‘...’
|
35 | freeze = ...
diff --git a/test/src/ghc-8.4.4-warning.compile.faceup
b/test/src/ghc-8.4.4-warning.compile.faceup
index 734a22e..9f652e5 100644
--- a/test/src/ghc-8.4.4-warning.compile.faceup
+++ b/test/src/ghc-8.4.4-warning.compile.faceup
@@ -10,7 +10,7 @@ Building library for stackage-to-hackage-1.1.0..
[1 of 2] Compiling StackageToHackage.Stackage (
lib/StackageToHackage/Stackage.hs,
/home/tseenshe/stack2cabal/dist-newstyle/build/x86_64-linux/ghc-8.4.4/stackage-to-hackage-1.1.0/noopt/build/StackageToHackage/Stackage.o
)
[2 of 2] Compiling StackageToHackage.Hackage (
lib/StackageToHackage/Hackage.hs,
/home/tseenshe/stack2cabal/dist-newstyle/build/x86_64-linux/ghc-8.4.4/stackage-to-hackage-1.1.0/noopt/build/StackageToHackage/Hackage.o
)
-«U:«:compilation-warning:lib/StackageToHackage/Hackage.hs»:«:compilation-line-number:13»:«:compilation-column-number:1»:
warning:» [-Wunused-imports]
+«U:«:compilation-warning:lib/StackageToHackage/Hackage.hs»»:«:compilation-line-number:13»:«:compilation-column-number:1»:
warning: [-Wunused-imports]
The qualified import of ‘Data.ByteString’ is redundant
except perhaps to import instances from ‘Data.ByteString’
To import instances alone, use: import Data.ByteString()
diff --git a/test/src/ghc-8.4.4-warningspan.compile.faceup
b/test/src/ghc-8.4.4-warningspan.compile.faceup
index b2bcd41..3be8863 100644
--- a/test/src/ghc-8.4.4-warningspan.compile.faceup
+++ b/test/src/ghc-8.4.4-warningspan.compile.faceup
@@ -10,7 +10,7 @@ Building library for stackage-to-hackage-1.1.0..
[1 of 2] Compiling StackageToHackage.Stackage
[2 of 2] Compiling StackageToHackage.Hackage
-«U:«:compilation-warning:lib/StackageToHackage/Hackage.hs»:«:compilation-line-number:13»:«:compilation-column-number:1»-«:compilation-column-number:51»:
warning:» [-Wunused-imports]
+«U:«:compilation-warning:lib/StackageToHackage/Hackage.hs»»:«:compilation-line-number:13»:«:compilation-column-number:1»-«:compilation-column-number:51»:
warning: [-Wunused-imports]
The qualified import of ‘Data.ByteString’ is redundant
except perhaps to import instances from ‘Data.ByteString’
To import instances alone, use: import Data.ByteString()
diff --git a/test/src/hspec-failure.compile.faceup
b/test/src/hspec-failure.compile.faceup
index a0fe49e..0e685b3 100644
--- a/test/src/hspec-failure.compile.faceup
+++ b/test/src/hspec-failure.compile.faceup
@@ -725,7 +725,7 @@ Hpack
Failures:
-«U:
«:compilation-error:test/HpackSpec.hs»:«:compilation-line-number:80»:«:compilation-column-number:15»:»
+
«U:«:compilation-error:test/HpackSpec.hs»»:«:compilation-line-number:80»:«:compilation-column-number:15»:
1) Hpack.hpackResult, with existing cabal file, when cabal file was created
with hpack >= 0.20.0, when hash is present, when exsting cabal file was
generated with a newer version of hpack, does not overwrite existing cabal file
not expected: "cabal-version: 1.12\n\n-- This file has been generated
from package.yaml by hpack version 0.22.0.\n--\n-- see:
https://github.com/sol/hpack\n--\n-- hash:
224b158530d1d066069f18794673f6a7a41f689d26f27fe8cd505cef259f35a9\n\nname:
foo\nversion: 0.1.0\nbuild-type: Simple\n"
- [nongnu] elpa/haskell-tng-mode a227f7e 200/385: blank lines end a run of type definitions, (continued)
- [nongnu] elpa/haskell-tng-mode a227f7e 200/385: blank lines end a run of type definitions, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode e4ead98 201/385: thots on prettify-symbol, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 387aa18 203/385: more efficient layout algorithm, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode bfc3841 193/385: remove bind-key dependency, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 6acba95 206/385: better insertion indentation on toplevels, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 9bfc6bf 215/385: really basic imenu, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode f648cf9 212/385: fallback to current directory (e.g. for cabal scripts), ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 5bdf688 211/385: better in-line indentation of parens, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 1cdf901 120/385: better escape syntax detection, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode c40c6e6 125/385: fix explicit export fontification bug, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 82312a2 126/385: working compilation matchers,
ELPA Syncer <=
- [nongnu] elpa/haskell-tng-mode 794c80b 131/385: better indentation alts, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode d43fd73 141/385: more efficient indentation 'insert test, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode a830fcb 135/385: reindention test, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode aa2a0ad 146/385: prefer --enable-tests, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode a754020 144/385: indent alts will suggest based on previous <- lines, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 9023dc6 164/385: don't rely on line-based indentation rules, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode fdaaf38 148/385: indent after "in", ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode e2c60a9 161/385: prep for records, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 8e4f438 184/385: don't continue indenting one liner types, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 5251477 186/385: thots, ELPA Syncer, 2021/10/06