by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Enrico Maria De Angelis
    @Aster89
    I just don't get how hlseach fits this :P
    I have a mapping for setting it on/off because I find it very useful
    Ben Jackson
    @puremourning
    it fits your test/toy example where it was in the same function you were currently in
    Enrico Maria De Angelis
    @Aster89
    Oh, okok
    I made the example so simple it is misleading :D
    Ben Jackson
    @puremourning
    right, your real use case is exactly why i added GoToSymbol
    tbh in C++ it's not that bad, but in java it's a total nightmare, cos even if you know what the file is called it is necessariliy in some massively complicated path structure requiring either a lot of typing or a lot of filesystem scanning. GoToSymbol is largely instant
    Enrico Maria De Angelis
    @Aster89
    Oh, I wander how useful it is, as I think I'll find it vital in C++ already :D
    Ben Jackson
    @puremourning
    yeah so far we've only implemented the 'dumbest' possible implementation, i.e. :YcmCompleter GoToSymbol <type stuff here>
    i'd like to be able to do something a bit smarter like provide some sort of completion using our filter-and-sort algorithm
    Enrico Maria De Angelis
    @Aster89
    I think I should add a mapping to prepopulate the command line with YcmCompleter GoToSymbol
    Ben Jackson
    @puremourning
    so maybe you could type :YcmCompleter GoToSymbol abc<Tab> and expand to :YcmCompleter GoToSymbol anotherBigClass
    yeah i use this:
    Enrico Maria De Angelis
    @Aster89
    That would be really useful
    i use input rather than just pre-poulate the command line because there's no completion right now and it reminds me what i need to enter, but you could just as easily just map to :YcmCompleter GoToSymbol
    Enrico Maria De Angelis
    @Aster89
    Wow, thanks
    I'll take most of them ;)
    Ben Jackson
    @puremourning
    err, most of my mappings in that file are overcomplicated because reasons
    i'm using repeat.vim, but it's pointless; i just haven't updated the file
    but anyway yes my mappings are esentially <leader>y<mnemonic for subcommand>
    ygd = go to 'defintion'
    ygt = go to type
    ygs = go to symbol
    etc
    Enrico Maria De Angelis
    @Aster89
    Yes, I think I'll have a mapping for each GoTo*
    Ben Jackson
    @puremourning
    fixit is useful one too. with clangd that includes 'code actions' like extract variable and extract function (or ycm-core/ycmd#1465 when we fix it)
    Enrico Maria De Angelis
    @Aster89
    Yeah, maybe it's time to add that too, even if it's in my fingers already
    It's just 7 keys, after all
    But the mapping would be 3 or 4
    Enrico Maria De Angelis
    @Aster89

    Wow, little interactions in more than 24 hours?! :P

    However, in studying boost::hana from my laptop, I've hit this strange behavior when completing. I remember that often the signature of the function whose call I'm filling is available even if I tab complete the arguments or whatever. Am I wrong?

    Clearly boost::hana has nothing to do, I just meant to say that I've recorded this on my laptop, not on my work computer where the I remember part is set.
    Yiming Pan
    @YimingPan
    Hello everybody! My YCM suddenly stopped working very recently. :messages shows no error, client and server logs are both empty.
    Yiming Pan
    @YimingPan
    nvm, it somehow recovered by itself after I robooted my laptop
    Ben Jackson
    @puremourning
    @Aster89 sorry i'm not following exactly what's the expected behaviour
    henglxm
    @henglxm
    Has anyone used php's intelephense language server?
    Enrico Maria De Angelis
    @Aster89
    @puremourning , for instance, I write auto xxx = hana::filter( and the popup with operator()(Xs &&xs, Pred &&pred) -> auto shows up, with Xs &&xs being highlighted, then I keep writing rest and then comma ,. If rest is a variable the popup disappears as soon as I hit that comma; if rest is not an existing name the popup stays unchanged, with Xs &&xs still highlighted, whereas Pred &&pred should be as I've inserted the comma, so I'm going to write the second argument.
    Boris Staletic
    @bstaletic
    Does rest have the correct type for hana::filter()?
    @henglxm I don't think so, but you can always try to set it up with :h g:ycm_language_server.
    Enrico Maria De Angelis
    @Aster89
    @bstaletic , no but I see the same behavior if I pass an object of the correct type
    Boris Staletic
    @bstaletic

    no

    In that case, you're seeing the correct behaviour. Because overloads.

    but I see the same behavior if I pass an object of the correct type

    A , is a trigger character for signature help. Check the logs. My guess is that clangd just gives up on Boost.Hana's template blackmagic.

    Enrico Maria De Angelis
    @Aster89
    Yes, it's really blackmagic :D
    What I should specifically check to ensure that clangd is giving up?
    Boris Staletic
    @bstaletic
    1. Set g:ycm_log_level to 'debug'.
    2. Recreate the behaviour with the comma.
    3. :YcmToggleLogs and choose the ycmd stderr one.
    4. Check the last textDocument/signatureHelp request to see its id.
    5. Check the corresponding response with the same id. I'm expecting it to be empty.
    The ycm_log_level should be set in your vimrc, since the config is only read at startup.
    When you finish, you likely want to remove that line, since it makes YCM log a lot.
    Ben Jackson
    @puremourning
    Yeah it’s likely that the types don’t match and so clangd doesn’t think there are any matching signatures.
    Or it doesn’t know the types and the same happens
    Boris Staletic
    @bstaletic
    Interestingly, with rust-analyzer, typing space closes the signature help.
    Enrico Maria De Angelis
    @Aster89
    This is the last line containing textDocument/signatureHelp:
    2020-08-10 09:15:35,687 - DEBUG - TX: Sending message: b'Content-Length: 175\r\n\r\n{"id":11,"jsonrpc":"2.0","method":"textDocument/signatureHelp","params":{"position":{"character":37,"line":56},"textDocument":{"uri":"file:///home/enrico/hanaExercises.cpp"}}}'
    Boris Staletic
    @bstaletic
    That line should be followed by a line containing RX:, "id":11 and "result":.
    Enrico Maria De Angelis
    @Aster89
    Since it says Sending message I guess it is a request. In which case, the id is 11, and the corresponding response should be:
    2020-08-10 09:15:35,708 - DEBUG - RX: Received message: b'{"id":11,"jsonrpc":"2.0","result":{"activeParameter":0,"activeSignature":0,"signatures":[]}}'