Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    Carlo Nucera
    @meditans
    does that mean that I should build ccls in debug mode @MaskRay
    ?
    probably cmake -G 'Unix Makefiles' -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_COMPILER=gcc is enough? Let me try
    Fangrui Song
    @MaskRay
    building ccls in debug mode can allow you to attach a debugger to the ccls process
    -G 'Unix Makefiles' can be omitted.
    Simon Pintarelli
    @simonpintarelli
    I'm using ccls with emacs, it seems that if I open a file located in a git worktree the root directory is wrongly determined. It takes the path to main git checkout. Is ccls computing the root directory or is that done by lsp-mode?
    Fangrui Song
    @MaskRay
    @simonpintarelli The root directory is computed by lsp-mode. emacs-ccls sets an advice: (advice-add 'lsp--suggest-project-root :before-until #'ccls--suggest-project-root)
    Simon Pintarelli
    @simonpintarelli
    Thank you.
    clauniel
    @clauniel
    Hi there. I'm having a problem with ccls indexing of dependencies. I have generated compile commands for my project, including commands for header files, using cmake and compdb. I see all the header files of my project in my compile_commands file, as well as the header files I am using from other libraries that I depend on. I have added the include directions of these libraries in my .ccls located in my project root. Everything works inside files directly inside my project. If I go to the definition of a symbol located in a dependency header file, ccls creates a .ccls-cache in the include directory of my dependency. ccls is unable to give me completions and the ability to go-to-definition from within the external library header file, even though those symbols can be accessed from header files inside my project. I am assuming this is because there is no .ccls located in the external library directory that defines -I directives to find the appropriate header files. Is there any way to make ccls use my project .ccls for external libraries as well? Especially given that the external header file in question actually has all include directives and compile options defined in my project compile_commands.json
    arj-singh
    @arj-singh
    Hi everyone, I've enabled ccls semantic highlighting on emacs, but it only updates when I save and write to a file. Is there a way to make it highlight as I'm typing?
    jaza-syed
    @jaza-syed
    Hi, I’m having some trouble getting ccls working on a toy project in emacs. ccls reports being unable to find header files, but if I use lsp-find-definition on the includes, it goes to the files (for both local and system includes). Would be very grateful for any help, I have explained in more detail here: MaskRay/emacs-ccls#88.
    jaza-syed
    @jaza-syed
    turns out this is just an instance of MaskRay/ccls#622
    Christian Maniewski
    @chmanie
    I am using coc.nvim as well and for some reason it's not picking up .h files. Is there any way to debug ccls there to see an error message?
    Christian Maniewski
    @chmanie
    I put %h -x c++-header into the .ccls file
    Well, using two separate lines like suggested here works: https://github.com/MaskRay/ccls/wiki/Project-Setup#h--hpp
    sbond75
    @sbond75
    Hi, I'm using ccls and it doesn't find headers like iostream, cstdio, or cstdint. It says ccls: cannot open file '/usr/local/Cellar/llvm/10.0.0_3/lib/clang/10.0.0/include/iostream': No such file or directory even though I set (setq ccls-args '( "-init='{\"clang\":{\"extraArgs\":[\"-isystem\", \"/Library/Developer/CommandLineTools/usr/include/c++/v1\"]}}'")) as recommended on https://github.com/MaskRay/ccls/issues/191#issuecomment-453809905 . I'm using macOS Catalina with llvm installed via Homebrew.
    Ghost
    @ghost~5ef21ad4d73408ce4fe7b2e5
    @chmanie Did you managed to solve this problem? I have the same issue, ccls sees headers like iostream but it does not see headers from my project, it looks like it is related to fact that I have headers in hdr folder and source in src, when I move them out to one folder it works just fine. My .ccls config is similar to Example A but extended with header parsing, I have minimal example if needed
    Christian Maniewski
    @chmanie
    @k-brk I think it's a different problem
    The headers are found for me but they were parsed as c headers
    arbernat
    @arbernat
    Hi. I'm also trying to get emacs working; in this case, emacs on Mac, tramp mode, and remote on a Linux dev VM. When I open a remote file I see ccls starting, and it starts logging output (redirected to /tmp)
    10:15:37 stdin            pipeline.cc:552 V(2) receive RequestMessage: 2 initialize
    10:15:37 ccls           initialize.cc:274 I initialize in directory /u/drew/src/purity with uri file:///u/drew/src/purity
    10:15:37 ccls           initialize.cc:297 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"diagnosticsRelatedInformation":true,"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxNum":100,"placeholder":true},"diagnostics":{"blacklist":[],"onChange":1000,"onOpen":0,"onSave":0,"spellChecking":true,"whitelist":[]},"highlight":{"largeFileSize":2097152,"lsRanges":false,"blacklist":[],"whitelist":[]},"index":{"blacklist":[],"comments":2,"initialNoLinkage":false,"initialBlacklist":[],"initialWhitelist":[],"maxInitializerLines":5,"multiVersion":0,"multiVersionBlacklist":[],"multiVersionWhitelist":[],"name":{"suppressUnwrittenScope":false},"onChange":false,"parametersInDeclarations":true,"threads":0,"trackDependency":2,"whitelist":[]},"request":{"timeout":5000},"session":{"maxNum":10},"workspaceSymbol":{"caseSensitivity":1,"maxNum":1000,"sort":true},"xref":{"maxNum":2000}}
    10:15:37 ccls           initialize.cc:329 I use -resource-dir=/usr/local/clang/lib/clang/10.0.0
    10:15:37 ccls             pipeline.cc:817 V(2) respond to RequestMessage: 2
    A bunch of "load cache" messages, then the last one is
    10:15:46 ccls             pipeline.cc:474 I loaded project. Refresh semantic highlight for all working file.
    Then the process exits
    Stephen Robinson
    @sudobash1
    Is there a way to set the size of types in a cross compiling setup? In the arm setup I am using a uint32_t is supposed to be %ul, but ccls is giving me warnings. I think I have -target set properly.
    Rafał Sarnikowski
    @Sarna555
    I'm using ccls with coc.nvim and my .cu files are not being processed, cpp files in the same projects seems to be working, is there any way to force ccls to treat .cu files as .cpp files?
    Fangrui Song
    @MaskRay
    MaskRay/ccls#662 Support $/progress and WorkDoneProgress{Begin,Report,End}
    @arbernat https://github.com/MaskRay/ccls/wiki/Debugging#dump-lsp-requestsresponses To intercept early requests/responses, you can use a shell script wrapper
    #!/bin/sh
    exec strace -s999 -e read,write -o /tmp/strace.log -f path/to/ccls "$@"
    Fangrui Song
    @MaskRay
    @sudobash1 %ul is wrong. Use %u or `"%" PRIu32
    @Sarna555 .cu files are indexed by default.
    Sameer Rahmani
    @lxsameer
    hey folks, i have cmake project which compiles fine, but ccls can't find system headers such as iostream
    I'm on linux and here is my cmake file https://paste.debian.net/1155163/
    Sameer Rahmani
    @lxsameer
    I'm using GCC I've tried : target_include_directories(<target> SYSTEM PRIVATE $ENV{INCLUDE}) as well
    Sameer Rahmani
    @lxsameer
    ignore me please, figured it out
    Rafał Sarnikowski
    @Sarna555
    @MaskRay ok, but somehow it's working on .cpp files and it's not working with .cu files
    pluswu
    @pluswu
    can coc and ale config the same ccls cachedir?
    fperies
    @fperies
    hello,
    I'm getting the following error when trying to get call hierarchy tree of a C++ function:
    ccls-call-hierarchy--request-children: Symbol s function definition is void: lsp:ccls-call-children
    Is it a well-known problem ?
    pluswu
    @pluswu
    ccls ale cache config sames does't work? ALEINFO ouput is: let g:ale_cpp_ccls_init_options = {'cacheDirectory': '/data/home/pluswu/.ccls_ale'}, but the cache is still in default .ccls-cache
    pluswu
    @pluswu
    let g:ale_c_ccls_init_options = { 'cache' : {'directory':'/tmp/ccls-ale'} } this format works fine for ale ccls cache dst
    fperies
    @fperies
    regarding my problem, I've just opened MaskRay/emacs-ccls#94
    fperies
    @fperies
    Ginger Old
    @laoshaw
    how can I get rid of ccls's c++17 extension warning, using vim(not vscode)
    1 reply
    jaza-syed
    @jaza-syed
    I'm using ccls in emacs and would like to get full semantic highlighting as in the he screenshots at https://github.com/MaskRay/emacs-ccls . I have (setq ccls-sem-highlight-method 'overlay) (ccls-use-default-rainbow-sem-highlight) in my config, but I still only get the emacs standard syntax highlighting (no highlights for calls to member functions, for example). Does anyone know how to configure this?
    skywb
    @skywb
    I can jump to the declatation, but ccls prompts me that the function cannot be matched, how can i fix it
    image.png
    image.png
    Sameer Rahmani
    @lxsameer
    hey folks, how can i force ccls to look for my local header files in an specific directory ?
    Krishnakumar Gopalakrishnan, PhD
    @krishnakumarg1984

    how can I get rid of ccls's c++17 extension warning, using vim(not vscode)

    Hi, any thoughts on this?

    Sergey Kuznetsov
    @kuznetsss_gitlab
    Hello, is there any way to limit cpu usage for indexing?
    George Xanthakis
    @innerout
    @kuznetsss_gitlab I think there is an option to limit the number of threads that create the index.