-
-
Notifications
You must be signed in to change notification settings - Fork 353
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Resolve for explicit-imports (#3682)
- Loading branch information
1 parent
e9cc4e0
commit 27f46d7
Showing
15 changed files
with
385 additions
and
202 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
376 changes: 209 additions & 167 deletions
376
plugins/hls-explicit-imports-plugin/src/Ide/Plugin/ExplicitImports.hs
Large diffs are not rendered by default.
Oops, something went wrong.
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
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module B where | ||
|
||
b1 :: String | ||
b1 = "b1" | ||
|
||
b2 :: String | ||
b2 = "b2" |
6 changes: 6 additions & 0 deletions
6
plugins/hls-explicit-imports-plugin/test/testdata/BreakFile.expected.hs
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{-# OPTIONS_GHC -Wall #-} | ||
module BreakFile whexe | ||
|
||
import A ( a1 ) | ||
|
||
main = putStrLn $ "hello " ++ a1 |
6 changes: 6 additions & 0 deletions
6
plugins/hls-explicit-imports-plugin/test/testdata/BreakFile.hs
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{-# OPTIONS_GHC -Wall #-} | ||
module BreakFile where | ||
|
||
import A | ||
|
||
main = putStrLn $ "hello " ++ a1 |
7 changes: 7 additions & 0 deletions
7
plugins/hls-explicit-imports-plugin/test/testdata/OnlyThis.expected.hs
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module OnlyThis where | ||
|
||
import A ( a1 ) | ||
import B | ||
|
||
main :: IO () | ||
main = putStrLn $ "hello " ++ a1 ++ b1 |
7 changes: 7 additions & 0 deletions
7
plugins/hls-explicit-imports-plugin/test/testdata/OnlyThis.hs
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module OnlyThis where | ||
|
||
import A | ||
import B | ||
|
||
main :: IO () | ||
main = putStrLn $ "hello " ++ a1 ++ b1 |
8 changes: 8 additions & 0 deletions
8
plugins/hls-explicit-imports-plugin/test/testdata/StaleAction.expected.hs
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{-# OPTIONS_GHC -Wall #-} | ||
module StaleAction where | ||
|
||
import A | ||
|
||
main = putStrLn $ "hello " ++ a1 | ||
|
||
testing = undefined |
6 changes: 6 additions & 0 deletions
6
plugins/hls-explicit-imports-plugin/test/testdata/StaleAction.hs
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{-# OPTIONS_GHC -Wall #-} | ||
module StaleAction where | ||
|
||
import A | ||
|
||
main = putStrLn $ "hello " ++ a1 |
2 changes: 1 addition & 1 deletion
2
plugins/hls-explicit-imports-plugin/test/testdata/UsualCase.expected.hs
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,4 +1,4 @@ | ||
module Main where | ||
module UsualCase where | ||
|
||
import A ( a1 ) | ||
|
||
|
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,4 +1,4 @@ | ||
module Main where | ||
module UsualCase where | ||
|
||
import A | ||
|
||
|
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,6 +1,10 @@ | ||
|
||
cradle: | ||
direct: | ||
arguments: | ||
- OnlyThis.hs | ||
- StaleAction.hs | ||
- UsualCase.hs | ||
- Exported.hs | ||
- A.hs | ||
- B.hs |
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
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