forked from haskell/haskell-language-server
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Batch load multi read #17
Open
soulomoon
wants to merge
27
commits into
master
Choose a base branch
from
batch-load-multi-read
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
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
… them to improve performance fix haskell#4381
…p error loading and cradle files
soulomoon
force-pushed
the
batch-load-multi-read
branch
from
November 9, 2024 12:06
ba7379b
to
79a43a0
Compare
Renames getOptions to getOptionsWorker for clarity Removes redundant getOptionsLoop function Ensures session loading is called under the same `Action` context
* Change FileDiagnostic type synonym to a datatype * Make `ideErrorWithSource` produce FileDiagnostic by adding filepath arg * Supply structured error wherever we easily can - TODOs for hard parts We're leaving the TODOs for either later in this PR or in another PR * Fix UnitTests for new FileDiagnostic struct * Remove explicit uses of FileDiagnostic, add codes to LSP diagnostics * Add field for expected error codes in ghcide tests * Expect GHC-83865 for "type error" test - basic test * Return structured warnings in TcModuleResult by copying from Driver * Store FileDiagnostic instead of LSP Diagnostic in Shake store * Add expected error codes for diagnostics that have them * Dispatch TODOs, amend remaining TODOs as future work * Add scary comments all over copied code in Compat.Driver * Update all remaining diagnostics that could use an expected error code * Add _code to pretty printing for FileDiagnostic * Use case instead of `maybe` for StructuredMessage match * Use CPP to prevent setting _code before structured errors * Swap modifier for lenses, document StructuredMessage type * Add link to Issue & MR to Compat.Driver * Drop attachReason logic from withWarnings, technically incorrect * Revert "Drop attachReason logic", needed by pragmas-plugin This reverts commit 4fed987. * Fix plugins where necessary for new diagnostic structure * Fix build issues with other tests from `expectDiagnostics` * Improve comment on metadata fdStructuredMessage in FileDiagnostic * Add note to withWarnings explaining the current state of things * Attach reasons into data field of LSP Diagnostic instead of code field Had to move `attachReason` between modules to achieve this, which is fine because it was never exported from its own module. * Fix up mistakes from merge, TODO fix merge issues for 9.3.0 * Set CodeDescription from HaskellErrorIndex when available * Remove debugging print, fix expectation for preprocessor tests * Fix CPP for using Show instance on DiagnosticCode * Remove diagFromErrMsgs for GHC version < 9.6.1 using CPP * CPP fix * More stylish-haskell, more CPP fix * Fix all stylish-haskell errors triggering * Fix more CPP * Only override the LSP diagnostic code when not already set * Fixes for stylish-haskell stylish-haskell does not handle CPP pragmas very well, is this a regression? * Qualify s, t for FuzzySearch * Ignore use of unsafePerformIO in FuzzySearch * Properly split GHC.Types.Error import in Diagnostics for stylish-haskell * Force type signature of annotation on FuzzySearch.dictionary * DRY up definition of closure_errs From review haskell#4311 (comment) * Remove unused imports * Post-rebase fixes * stylish-haskell formatting * Fix issue with GHC 9.4 * Please stylish-haskell * Ignore error codes when testing GHC 9.4 * Workaround darwin GHC bug in hls-hlint-plugin * Put the workaround in the right place * Revert "Set CodeDescription from HaskellErrorIndex when available" This reverts commit 14d6697. * Resolve fendor's feedback * Apply stylish-haskell formatting * Apply more stylish-haskell formatting * Resolve some of soulomoon's feedback * Fix small issues * Remove unused imports * Remove StructuredDiagnostic * Revert "Remove StructuredDiagnostic" This reverts commit 0776c65. * Remove the unused parameter from 'ideErrorText' * Add documentation to diagnostic helpers * Add action to query active diagnostics for a given Range Implement 'rangesOverlap' function which checks whether two 'Range's overlap in any way. Implement two new plugin utility functions which allow to conveniently get all currently displayed diagnostics for a given 'Range'. * Use lens for updating Diagnostic * Add GHC Structured Error compatibility module Add compatibility module for GHC's structured error messages. Introduce 'Prism's and 'Lens's to easily access nested structures. Expand documentation for 'StructuredMessage' * Remove unused imports * Don't suggest -Wno-deferred-out-of-scope-variables (haskell#4441) Fixes haskell#4440 Fixes test for disabling deferred-type-errors. * Build HLS with GHC 9.8.3 (haskell#4444) * ci(mergify): upgrade configuration to current format (haskell#4454) Co-authored-by: Mergify <37929162+mergify[bot]@users.noreply.github.com> * More tests and better docs for cabal-add (haskell#4455) * new tests * change codeAction title * more tests and docs --------- Co-authored-by: fendor <[email protected]> * Fix compatibility with GHC 9.4 and rename function * Use GHC Note syntax and reference Note in docs Allows HLS to 'Goto Definition' for Note references. * Add doc comment for 'tmrWarnings' * Push CPP statements to compatibility module * Fix formatting in Development.IDE.GHC.Compat.Error --------- Co-authored-by: Dylan Thinnes <[email protected]> Co-authored-by: soulomoon <[email protected]> Co-authored-by: Fendor <[email protected]> Co-authored-by: jeukshi <[email protected]> Co-authored-by: fendor <[email protected]> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> Co-authored-by: Georgii Gerasev <[email protected]>
) Bumps [haskell-actions/setup](https://github.com/haskell-actions/setup) from 2.7.7 to 2.7.8. - [Release notes](https://github.com/haskell-actions/setup/releases) - [Commits](haskell-actions/setup@v2.7.7...v2.7.8) --- updated-dependencies: - dependency-name: haskell-actions/setup dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [haskell-actions/setup](https://github.com/haskell-actions/setup) from 2.7.7 to 2.7.8. - [Release notes](https://github.com/haskell-actions/setup/releases) - [Commits](haskell-actions/setup@v2.7.7...v2.7.8) --- updated-dependencies: - dependency-name: haskell-actions/setup dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.