Giter Club home page Giter Club logo

Comments (6)

expez avatar expez commented on September 24, 2024

I'd like to avoid doing something like this, @bbatsov:

(defun company-quickhelp--doc (selected)
  (cl-letf (((symbol-function 'cider--var-choice) (lambda (_) (error "Ambiguous candidate!"))))
    ...))

Could we perhaps introduce *cider--tooling-context* which tools can bind to t before calling into CIDER? In the case of the documentation buffer, an empty buffer, or one containing a short text stating that documentation isn't available before disambiguation would make sense.

from company-quickhelp.

dgutov avatar dgutov commented on September 24, 2024

Maybe you can bind completing-read-function locally to one that just picks the first option?

from company-quickhelp.

expez avatar expez commented on September 24, 2024

Yeah, that's a good idea, and more general than the hack I put in my .emacs while deliberating what to do about this.

My concern was that the popup would be misleading, and it would be better to fail gracefully and let the user know about the situation. But the popup already is misleading, the annotations are all out of whack in these situations, and the user might prefer seeing documentation for one of the candidates rather than an entirely unhelpful message about ambiguity.

from company-quickhelp.

bbatsov avatar bbatsov commented on September 24, 2024

You can also merge all possible candidates I guess.

On 18 April 2015 at 10:01, Lars Andersen [email protected] wrote:

Closed #8 #8 via
ef01c60
ef01c60
.


Reply to this email directly or view it on GitHub
#8 (comment).

Best Regards,
Bozhidar Batsov

http://www.batsov.com

from company-quickhelp.

dgutov avatar dgutov commented on September 24, 2024

That might require some tricky inversion of control, though: then the amount of times this frontend would call doc-buffer would be dependent on how much (and if at all) completing-read was called during the first doc-buffer call. Should be doable, though.

Could also be slow for certain methods.

from company-quickhelp.

expez avatar expez commented on September 24, 2024

Merge all candidates as in display all the docs? java docstrings--at least those in the standard library--are often the length of novels so that's going to get out of hand real quick :)

from company-quickhelp.

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.