Git Product home page Git Product logo

Comments (9)

hvr avatar hvr commented on July 21, 2024 2

Fwiw, if you M-x package-install haskell-snippets, you get autocompletion via https://github.com/haskell/haskell-snippets/blob/master/snippets/haskell-mode/lang-pragma

from dante.

bezirg avatar bezirg commented on July 21, 2024 1

I do have completion of LANGUAGE pragmas, when using the standard haskell-mode package combined with company auto-completion package. Just make sure that company-capf is part of the local variable company-backends:

(add-hook 'dante-mode-hook
          (lambda ()
            (company-mode)
            (set (make-local-variable 'company-backends)
                 '(company-capf))))

from dante.

jyp avatar jyp commented on July 21, 2024

The best method is to use autofix: use the extension first then use autofix on the error.

from dante.

sellout avatar sellout commented on July 21, 2024

@Fresheyeball structured-haskell-mode also does this (I think ā€¦ at least, some mode Iā€™m using does) and should work fine with Dante.

from dante.

Fresheyeball avatar Fresheyeball commented on July 21, 2024

@sellout I'm using the structured-haskell-mode for this now. But I would rather have better separation of concerns. structured-haskell-mode does it through stack I'd like it to be independent.

from dante.

jyp avatar jyp commented on July 21, 2024

The way that company mode is structured, you can add a completer which only completes pragmas. (This functionality has nothing to do with GHCi and thus I do not think that it belongs in dante.)

from dante.

purcell avatar purcell commented on July 21, 2024

I do have completion of LANGUAGE pragmas, when using the standard haskell-mode package combined with company auto-completion package. Just make sure that company-capf is part of the local variable company-backends:

The issue I found with this is that company-capf and dante-company fight about who should get to complete a symbol. I submitted #118 in order to have dante-company punt when asked to complete inside a comment, which allows the haskell-mode pragma completion to kick in with just the standard dante config.

from dante.

purcell avatar purcell commented on July 21, 2024

The fix for this has been merged, so the issue can probably be closed if someone would like to confirm it works for them with the stock company configuration.

from dante.

jyp avatar jyp commented on July 21, 2024

Yep, this works. Thanks @purcell.

from dante.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    šŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. šŸ“ŠšŸ“ˆšŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ā¤ļø Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.