@aliu yes
Search Criteria
Package Details: clangd-opt-git 20.r19078.g1f26ac10ca1b-1
Package Actions
Git Clone URL: | https://aur.archlinux.org/clangd-opt-git.git (read-only, click to copy) |
---|---|
Package Base: | clangd-opt-git |
Description: | Trunk version of standalone clangd binary, with custom patches (look AUR page or PKGBUILD comments) |
Upstream URL: | https://llvm.org/ |
Licenses: | Apache-2.0 WITH LLVM-exception |
Conflicts: | clangd-opt |
Provides: | clangd-opt |
Replaces: | clangd-opt |
Submitter: | sr.team |
Maintainer: | sr.team |
Last Packager: | sr.team |
Votes: | 2 |
Popularity: | 0.001380 |
First Submitted: | 2024-03-15 10:25 (UTC) |
Last Updated: | 2025-02-08 04:34 (UTC) |
Dependencies (18)
- gcc-libs (gcc-libs-gitAUR, gccrs-libs-gitAUR, gcc11-libsAUR, gcc-libs-snapshotAUR)
- glibc (glibc-gitAUR, glibc-linux4AUR, glibc-eacAUR)
- ncurses (ncurses-gitAUR)
- zlib (zlib-ng-compat-gitAUR, zlib-gitAUR, zlib-ng-compat)
- zstd (zstd-gitAUR, zstd-staticAUR)
- cmake (cmake-gitAUR, cmake3AUR) (make)
- git (git-gitAUR, git-glAUR) (make)
- libedit (make)
- libffi (libffi-gitAUR) (make)
- libxml2 (libxml2-gitAUR, libxml2-2.9AUR) (make)
- ncurses (ncurses-gitAUR) (make)
- ninja (ninja-kitwareAUR, ninja-memAUR, ninja-fuchsia-gitAUR, ninja-gitAUR, ninja-jobserverAUR) (make)
- patch (patch-gitAUR) (make)
- python-psutil (make)
- python-setuptools (make)
- python-sphinx (python-sphinx-gitAUR) (make)
- zlib (zlib-ng-compat-gitAUR, zlib-gitAUR, zlib-ng-compat) (make)
- zstd (zstd-gitAUR, zstd-staticAUR) (make)
Required by (0)
Sources (22)
- doxygen-extra-render-trunk.patch
- doxygen-more-fields.patch
- git+https://github.com/llvm/llvm-project.git#branch=main
- hover-bit-fields-mask.patch
- hover-doxygen-trunk.patch
- hover-field-idx.patch
- hover-hex-formats.patch
- hover-layout-everyhere.patch
- hover-no-defs.patch
- hover-record-paddings.patch
- hover-resolve-forward-params.patch
- hover-virt-offset.patch
- implement-abstract-class.patch
- inlay-hints-blockend-linelimit10.patch
- inlay-hints-hide-deduced-types-ignore-evident.patch
- inlay-hints-paddings.patch
- lsp-codelens.patch
- lsp-preprocessor-folding.patch
- lsp-remove-files-from-cdb.patch
- postfix-completion-trunk.patch
- refactor-extract-function.patch
- resolve-incomplete-header-includes.patch
sr.team commented on 2025-02-20 18:27 (UTC)
aliu commented on 2025-02-19 21:13 (UTC) (edited on 2025-02-19 21:16 (UTC) by aliu)
But none of these failed tests are due to the way I adapted the dependent types resolution patch to work, right? You can see how I adapted it in https://github.com/llvm/llvm-project/commit/3be440ad4de88b530fef31f3bdfe91817e93ef7a (though part of it deals with reverting an earlier hack I did).
sr.team commented on 2025-02-10 08:24 (UTC) (edited on 2025-02-10 08:27 (UTC) by sr.team)
On branch 21 broken symbol and hover providers.
It's not bug of provided patches in this AUR. With clear clangd build, issue is still: in some files clangd stuck on resolving local symbols and hover information (code completion continue works).
Commit as known is not affected: b80965efc1ea (from branch 20)
aliu commented on 2025-02-08 16:10 (UTC) (edited on 2025-02-08 16:11 (UTC) by aliu)
I got resolving dependent types working at https://github.com/aaronliu0130/clangd-opt by moving some of the AST.h functions into clang/Instantiation.h. I also fixed the compilation of tests so that they now fail instead of failing to compile.
Failed Tests (34)
Failed Tests (34): Clangd :: hover.test Clangd :: index-serialization/version-is-correct.test Clangd Unit Tests :: ./ClangdTests/BlockEndHints/Functions Clangd Unit Tests :: ./ClangdTests/BlockEndHints/If Clangd Unit Tests :: ./ClangdTests/BlockEndHints/Loops Clangd Unit Tests :: ./ClangdTests/BlockEndHints/Macro Clangd Unit Tests :: ./ClangdTests/BlockEndHints/Methods Clangd Unit Tests :: ./ClangdTests/BlockEndHints/Namespaces Clangd Unit Tests :: ./ClangdTests/BlockEndHints/PointerToMemberFunction Clangd Unit Tests :: ./ClangdTests/BlockEndHints/PrintConversions Clangd Unit Tests :: ./ClangdTests/BlockEndHints/PrintLiterals Clangd Unit Tests :: ./ClangdTests/BlockEndHints/PrintOperators Clangd Unit Tests :: ./ClangdTests/BlockEndHints/PrintRefs Clangd Unit Tests :: ./ClangdTests/BlockEndHints/Switch Clangd Unit Tests :: ./ClangdTests/BlockEndHints/TrailingSemicolon Clangd Unit Tests :: ./ClangdTests/BlockEndHints/TrailingText Clangd Unit Tests :: ./ClangdTests/BlockEndHints/Types Clangd Unit Tests :: ./ClangdTests/CompletionStringTest/DoxygenParsing Clangd Unit Tests :: ./ClangdTests/CompletionStringTest/GetDeclDocumentationBadUTF8 Clangd Unit Tests :: ./ClangdTests/CompletionTest/Documentation Clangd Unit Tests :: ./ClangdTests/CompletionTest/RenderWithFixItMerged Clangd Unit Tests :: ./ClangdTests/ExtractFunctionTest/FileTest Clangd Unit Tests :: ./ClangdTests/Hover/All Clangd Unit Tests :: ./ClangdTests/Hover/HideBigInitializers Clangd Unit Tests :: ./ClangdTests/Hover/Present Clangd Unit Tests :: ./ClangdTests/Hover/SpaceshipTemplateNoCrash Clangd Unit Tests :: ./ClangdTests/Hover/Structured Clangd Unit Tests :: ./ClangdTests/Hover/Typedefs Clangd Unit Tests :: ./ClangdTests/InlayHints/RestrictRange Clangd Unit Tests :: ./ClangdTests/SymbolCollectorTest/DocumentationAtDeclThenDef Clangd Unit Tests :: ./ClangdTests/TypeHints/Decltype Clangd Unit Tests :: ./ClangdTests/TypeHints/Deduplication Clangd Unit Tests :: ./ClangdTests/TypeHints/Smoke Clangd Unit Tests :: ./ClangdTests/TypeHints/SubstTemplateParameterAliases
sr.team commented on 2025-02-08 04:44 (UTC)
Sorry for forgetting to send updated patches in January.
Also about the Resolve includes in non-self-contained headers
patch - I'm thinking about remove it. This patch bugged as described here - sometime non-self-contained headers still broken, and sometimes it's broke analyzer in source files
aliu commented on 2025-02-08 04:04 (UTC)
I rebased the patches against snapshot 21.x at https://github.com/aaronliu0130/clangd-opt.
phush0 commented on 2025-01-06 08:59 (UTC)
Resolve includes in non-self-contained headers do not apply and need to be rebased
aliu commented on 2025-01-02 03:24 (UTC)
Thanks!
sr.team commented on 2025-01-02 03:17 (UTC)
@aliu, thanks! You're right - the pseudo-parser is not needed for this patch to work! I restored the rebased version of this patch.
aliu commented on 2025-01-01 22:37 (UTC) (edited on 2025-01-01 22:40 (UTC) by aliu)
@sr_team The commit that removed clang-pseudo moved DirectiveTree(.h/.cpp) to llvm-project/clang-tools-extra/clangd/support/DirectiveTree(.h/.cpp) .
Pinned Comments
sr.team commented on 2024-03-15 10:25 (UTC) (edited on 2025-02-08 04:57 (UTC) by sr.team)
This PKGBUILD build trunk version of clangd, and may apply some non-standard patches
Applying patches controls via enviroment variables (e.g.
CLANGD_DEFAULT_PATCH_STATE=y makepkg -si
)List of patches and environment variables to enable them
Toggle all below patches
CLANGD_DEFAULT_PATCH_STATE
:Apply user patches from
~/.config/clangd
. Patches must have extension*.patch
NOTE: This variable ignores the
CLANGD_DEFAULT_PATCH_STATE
variableCLANGD_USER_PATCHES
:For each of the following patches, set the corresponding environment variable to:
Show Doxygen comments in hover (D134130)
CLANGD_DOXYGEN
Resolve forwarded parameters in hover (D130265)
CLANGD_RESOLVEFWDPARAMS
Implement textDocument/codeLens (D91930)
It's also required patched
vscode-clangd
extension - vscode-clangd/46266b4adb106b5080f5c771099c777806a16adcCLANGD_CODELENS
Contextual postfix completions (D125224)
Demo: asciinema.org/a/rxyoicX44ya2jLDpdbNj3rVcC
CLANGD_POSTFIXCOMPLETION
Extract Function: add hoisting support (D138499)
CLANGD_EXTRACTFUNC
Add inlay hints for structure paddings
CLANGD_INLAYHINTSPADS
Add hex formats in
size
andoffset
fields on hover, when values more than 10CLANGD_HOVERINHEX
Show mask for bit fields on hover
Demo: Screen 1, Screen 2
CLANGD_HOVERBITFIELDSMASK
Show offset of virtual methods
Limitations: supports only Itanium and MS abi
CLANGD_HOVERVIRTOFF
Show layout hover info everyhere
CLANGD_HOVERLAYOUTEVERYHERE
Hide definition from hover info for functions and variables
CLANGD_HOVERNODEFS
Resolve the dependent type from its single instantiation (PR: 71279)
CLANGD_RESOLVEDEPTYPE
Increase minimal limit for BlockEnd inlay-hints to 10 lines (default is 2)
This disabled show BlockEnd inlay-hints for small functions (less than 10 lines)
CLANGD_INLAYHINTSBLOCKEND
Resolve includes in non-self-contained headers
Limitations: AST for source must be loaded before open incomplete header
CLANGD_RESOLVEINCHEADERS
Add way to remove files from CDB via LSP
No need in many cases. Useful only in multi project workspaces with patched client
CLANGD_LSPREMOVEFROMCDB
Show total record paddings in hover
CLANGD_HOVERRECORDPAD
Add tweak for implementing abstract class (D94942)
CLANGD_IMPL_ABSTRACT_CLASS
Hover information: Show fields indexes in layout:
Offset: 8 bytes (index 1)
CLANGD_HOVERFIELDIDX
Inlay hints: Ignore evident types in deduced types
CLANGD_INLAYHINTSIGNOREEVIDENT
Implement simple folding of preprocessor branches (PR: 80592)
CLANGD_PREPROCESSOR_FOLDING