Skip to content
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

Use exact print to extend import lists #1246

Merged
merged 11 commits into from
Jan 23, 2021

Conversation

berberman
Copy link
Collaborator

@berberman berberman commented Jan 22, 2021

Rework haskell/ghcide#942

Things to do:

  • Replace mkVarName and mkTcClsName with parseIdentifier
  • Compatible with multiple GHC versions
  • Apply changes to CodeAction.hs
  • Make tests pass

@berberman
Copy link
Collaborator Author

Parsed source returned by GetAnnotatedParsedSource does not preserve comments, so rewriting may cause stripping of inline comments.

@pepeiborra Can I change the following GetParsedModule to GetParsedModuleWithComments ?

@pepeiborra pepeiborra marked this pull request as ready for review January 23, 2021 08:53
Copy link
Collaborator

@pepeiborra pepeiborra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fantastic work, thank you so much!

@berberman berberman changed the title Draft: Use exact print to extend import lists Use exact print to extend import lists Jan 23, 2021
@berberman
Copy link
Collaborator Author

Hmm, the test suite of eval plugin failed again and again...

@jneira jneira merged commit 3464ed8 into haskell:master Jan 23, 2021
@pepeiborra
Copy link
Collaborator

@berberman with this change and a bit more work I think we can restore the work that @gdevanla did to automatically extend imports on completions. Do you or @gdevanla already plan to do it?

@gdevanla
Copy link
Contributor

I have been busy and have not caught up with many things that have happened since last month. I know @pepeiborra had to disable extending imports. I can take a look at it if @berberman has not already done any work on that.

@berberman berberman deleted the extend-import-list-exactprint branch January 24, 2021 02:25
@berberman
Copy link
Collaborator Author

berberman commented Jan 24, 2021

@pepeiborra I'm not familiar with code responsible for completions, and have not investigated yet. So please let @gdevanla do that.

@pepeiborra
Copy link
Collaborator

@gdevanla @berberman I was actually planning to look at it today, was just checking that no one else was already working on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants