diff options
author | Alan Zimmerman <alan.zimm@gmail.com> | 2022-12-13 23:30:52 +0000 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-12-22 23:38:35 -0500 |
commit | 3699a5542caa88a8718588e68549b6291bcb5bfc (patch) | |
tree | 7b6697260afde589dc05aef808a1bf8ce07b1ccc /testsuite | |
parent | b2c7523d8987bedf13a7dd682d836ffb76cbe09d (diff) | |
download | haskell-3699a5542caa88a8718588e68549b6291bcb5bfc.tar.gz |
EPA: Make EOF position part of AnnsModule
Closes #20951
Closes #19697
Diffstat (limited to 'testsuite')
16 files changed, 96 insertions, 130 deletions
diff --git a/testsuite/tests/ghc-api/exactprint/LocalDecls2.expected.hs b/testsuite/tests/ghc-api/exactprint/LocalDecls2.expected.hs index d2353e94c5..f015e958e9 100644 --- a/testsuite/tests/ghc-api/exactprint/LocalDecls2.expected.hs +++ b/testsuite/tests/ghc-api/exactprint/LocalDecls2.expected.hs @@ -4,5 +4,3 @@ foo a = bar a where nn :: Int nn = 2 - - diff --git a/testsuite/tests/ghc-api/exactprint/Test20239.stderr b/testsuite/tests/ghc-api/exactprint/Test20239.stderr index bcbb818b05..8bfb5085ce 100644 --- a/testsuite/tests/ghc-api/exactprint/Test20239.stderr +++ b/testsuite/tests/ghc-api/exactprint/Test20239.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { Test20239.hs:8:1 } + { Test20239.hs:7:34-63 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { Test20239.hs:8:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { Test20239.hs:7:34-63 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/haddock/should_compile_flag_haddock/T17544.stderr b/testsuite/tests/haddock/should_compile_flag_haddock/T17544.stderr index 212f3f9bec..484a56ecc0 100644 --- a/testsuite/tests/haddock/should_compile_flag_haddock/T17544.stderr +++ b/testsuite/tests/haddock/should_compile_flag_haddock/T17544.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T17544.hs:57:1 } + { T17544.hs:55:18-20 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { T17544.hs:57:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T17544.hs:57:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/haddock/should_compile_flag_haddock/T17544_kw.stderr b/testsuite/tests/haddock/should_compile_flag_haddock/T17544_kw.stderr index 28f3f4ef63..1efed5e02e 100644 --- a/testsuite/tests/haddock/should_compile_flag_haddock/T17544_kw.stderr +++ b/testsuite/tests/haddock/should_compile_flag_haddock/T17544_kw.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T17544_kw.hs:25:1 } + { T17544_kw.hs:24:18 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { T17544_kw.hs:25:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T17544_kw.hs:25:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/module/mod185.stderr b/testsuite/tests/module/mod185.stderr index f5dbe2fa70..b9e5ee7849 100644 --- a/testsuite/tests/module/mod185.stderr +++ b/testsuite/tests/module/mod185.stderr @@ -16,16 +16,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { mod185.hs:6:1 } + { mod185.hs:5:8-24 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { mod185.hs:6:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { mod185.hs:6:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/DumpParsedAst.stderr b/testsuite/tests/parser/should_compile/DumpParsedAst.stderr index fdea6a5bce..1e48180185 100644 --- a/testsuite/tests/parser/should_compile/DumpParsedAst.stderr +++ b/testsuite/tests/parser/should_compile/DumpParsedAst.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { DumpParsedAst.hs:25:1 } + { DumpParsedAst.hs:24:17-23 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { DumpParsedAst.hs:25:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { DumpParsedAst.hs:25:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/DumpParsedAstComments.stderr b/testsuite/tests/parser/should_compile/DumpParsedAstComments.stderr index 0f451eeb14..6050639d73 100644 --- a/testsuite/tests/parser/should_compile/DumpParsedAstComments.stderr +++ b/testsuite/tests/parser/should_compile/DumpParsedAstComments.stderr @@ -18,7 +18,11 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { DumpParsedAstComments.hs:17:1 } + { DumpParsedAstComments.hs:16:17-23 }))) (EpaCommentsBalanced [(L (Anchor @@ -44,13 +48,7 @@ (EpaLineComment "-- Other comment") { DumpParsedAstComments.hs:5:30-34 }))] - [(L - (Anchor - { DumpParsedAstComments.hs:17:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { DumpParsedAstComments.hs:17:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/DumpSemis.stderr b/testsuite/tests/parser/should_compile/DumpSemis.stderr index faa926b6c4..4e283a73fe 100644 --- a/testsuite/tests/parser/should_compile/DumpSemis.stderr +++ b/testsuite/tests/parser/should_compile/DumpSemis.stderr @@ -28,16 +28,14 @@ ,(AddSemiAnn (EpaSpan { DumpSemis.hs:4:7 })) ,(AddSemiAnn - (EpaSpan { DumpSemis.hs:4:8 }))])) + (EpaSpan { DumpSemis.hs:4:8 }))]) + (Just + ((,) + { DumpSemis.hs:46:1 } + { DumpSemis.hs:45:1 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { DumpSemis.hs:46:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { DumpSemis.hs:46:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/KindSigs.stderr b/testsuite/tests/parser/should_compile/KindSigs.stderr index f9b9a986e4..df228cb912 100644 --- a/testsuite/tests/parser/should_compile/KindSigs.stderr +++ b/testsuite/tests/parser/should_compile/KindSigs.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { KindSigs.hs:36:1 } + { KindSigs.hs:35:8-11 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { KindSigs.hs:36:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { KindSigs.hs:36:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/T15323.stderr b/testsuite/tests/parser/should_compile/T15323.stderr index 36768671e4..a3bc49d34f 100644 --- a/testsuite/tests/parser/should_compile/T15323.stderr +++ b/testsuite/tests/parser/should_compile/T15323.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T15323.hs:7:1 } + { T15323.hs:6:54 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { T15323.hs:7:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T15323.hs:7:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/T20452.stderr b/testsuite/tests/parser/should_compile/T20452.stderr index 0c2982dd9c..f05cef65b8 100644 --- a/testsuite/tests/parser/should_compile/T20452.stderr +++ b/testsuite/tests/parser/should_compile/T20452.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T20452.hs:10:1 } + { T20452.hs:9:85 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { T20452.hs:10:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T20452.hs:10:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/T20718.stderr b/testsuite/tests/parser/should_compile/T20718.stderr index ab90eb29bc..bd071a0227 100644 --- a/testsuite/tests/parser/should_compile/T20718.stderr +++ b/testsuite/tests/parser/should_compile/T20718.stderr @@ -17,7 +17,11 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T20718.hs:12:1 } + { T20718.hs:11:1-8 }))) (EpaCommentsBalanced [(L (Anchor @@ -51,13 +55,7 @@ (EpaLineComment "-- before 2") { T20718.hs:5:1-11 }))] - [(L - (Anchor - { T20718.hs:12:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T20718.hs:11:1-8 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/T20718b.stderr b/testsuite/tests/parser/should_compile/T20718b.stderr index 79b5d67bb3..6370f1cbcc 100644 --- a/testsuite/tests/parser/should_compile/T20718b.stderr +++ b/testsuite/tests/parser/should_compile/T20718b.stderr @@ -17,7 +17,11 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T20718b.hs:8:1 } + { T20718b.hs:7:1-21 }))) (EpaCommentsBalanced [(L (Anchor @@ -51,13 +55,7 @@ (EpaLineComment "-- trailing comment 2") { T20718b.hs:6:1-21 }))] - [(L - (Anchor - { T20718b.hs:8:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T20718b.hs:7:1-21 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/parser/should_compile/T20846.stderr b/testsuite/tests/parser/should_compile/T20846.stderr index edacbd9ff6..7cb906a78a 100644 --- a/testsuite/tests/parser/should_compile/T20846.stderr +++ b/testsuite/tests/parser/should_compile/T20846.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T20846.hs:5:1 } + { T20846.hs:4:10-18 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { T20846.hs:5:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T20846.hs:5:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/printer/T18791.stderr b/testsuite/tests/printer/T18791.stderr index 52c97faba4..28727aabf6 100644 --- a/testsuite/tests/printer/T18791.stderr +++ b/testsuite/tests/printer/T18791.stderr @@ -17,16 +17,14 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { T18791.hs:6:1 } + { T18791.hs:5:17 }))) (EpaCommentsBalanced [] - [(L - (Anchor - { T18791.hs:6:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { T18791.hs:6:1 }))])) + [])) (VirtualBraces (1)) (Nothing) diff --git a/testsuite/tests/printer/Test20297.stdout b/testsuite/tests/printer/Test20297.stdout index 9a220e21db..df6f3347f9 100644 --- a/testsuite/tests/printer/Test20297.stdout +++ b/testsuite/tests/printer/Test20297.stdout @@ -17,7 +17,11 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { Test20297.hs:12:1 } + { Test20297.hs:11:22-26 }))) (EpaCommentsBalanced [(L (Anchor @@ -27,13 +31,7 @@ (EpaBlockComment "{-# OPTIONS -ddump-parsed-ast #-}") { Test20297.hs:1:1 }))] - [(L - (Anchor - { Test20297.hs:12:1 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { Test20297.hs:12:1 }))])) + [])) (VirtualBraces (1)) (Nothing) @@ -364,7 +362,11 @@ (Nothing) (Nothing) [] - [])) + []) + (Just + ((,) + { Test20297.ppr.hs:9:25 } + { Test20297.ppr.hs:9:20-24 }))) (EpaCommentsBalanced [(L (Anchor @@ -374,13 +376,7 @@ (EpaBlockComment "{-# OPTIONS -ddump-parsed-ast #-}") { Test20297.ppr.hs:1:1 }))] - [(L - (Anchor - { Test20297.ppr.hs:9:25 } - (UnchangedAnchor)) - (EpaComment - (EpaEofComment) - { Test20297.ppr.hs:9:20 }))])) + [])) (VirtualBraces (1)) (Nothing) |