[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2022-02-28 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks added a comment. I have a similar structure to Qt regarding the headers and use clangd trough the QtCreator, so for my own libraries I cannot use the auto completion. In D112996#3102782 , @sammccall wrote: >> the files are located in

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Thanks Christian! Sorry for the delay. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://reviews.llvm.org/D112996 ___ cfe-commits mailing list cfe-commits@lists

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-09 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf7500a4ef7bd: [CodeCompletion] Generally consider header files without extension (authored by ckandeler, committed by sammccall). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:/

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-09 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler updated this revision to Diff 385826. ckandeler added a comment. Added test cases. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://reviews.llvm.org/D112996 Files: clang/lib/Sema/SemaCodeComplete.cpp clang/test/CodeC

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D112996#3106469 , @ckandeler wrote: > In D112996#3106459 , @sammccall > wrote: > >> can we the tests again though? > > Sorry, I don't understand what you mean by that. Apologies, I

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-09 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler added a comment. Can someone please merge this? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://reviews.llvm.org/D112996 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-08 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler updated this revision to Diff 385453. ckandeler added a comment. Addressed formatting comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://reviews.llvm.org/D112996 Files: clang/lib/Sema/SemaCodeComplete.cpp Ind

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-03 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler added a comment. In D112996#3106459 , @sammccall wrote: > can we the tests again though? Sorry, I don't understand what you mean by that. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-03 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler added inline comments. Comment at: clang/lib/Sema/SemaCodeComplete.cpp:9619 +const bool ExtensionlessHeaders = IsSystem || isQt +|| Dir.endswith(".framework/Headers"); std::error_code EC; I'm just noticing that this is often a symlink i

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-03 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. LG, thanks! can we the tests again though? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://reviews.llvm.org/D112996 ___

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-03 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler updated this revision to Diff 384485. ckandeler added a comment. Addressed comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://reviews.llvm.org/D112996 Files: clang/lib/Sema/SemaCodeComplete.cpp Index: clang/l

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-03 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D112996#3105783 , @ckandeler wrote: >>> For framework builds, the directory would be "Headers", which also seems >>> safe. >> >> I agree extensionless headers in frameworks seem fine to show. >> We already know which include

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-03 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler added a comment. >> For framework builds, the directory would be "Headers", which also seems >> safe. > > I agree extensionless headers in frameworks seem fine to show. > We already know which includepath entries are frameworks, so we can just use > that info directly (see line 9674)

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-03 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler updated this revision to Diff 384407. ckandeler added a comment. Limited the matching to Qt headers. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://reviews.llvm.org/D112996 Files: clang/lib/Sema/SemaCodeComplete.cpp

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-02 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D112996#3102925 , @ckandeler wrote: >> WDYT about detecting QT headers specifically? It seems hacky, but I don't >> see a way out of this that doesn't involve hardcoding some filenames. Are >> they in a directory like `"qt-

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-02 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler added a comment. > WDYT about detecting QT headers specifically? It seems hacky, but I don't see > a way out of this that doesn't involve hardcoding some filenames. Are they in > a directory like `"qt-11/QFoo"` that we can recognize? Even Q followed by > another capital letter might b

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-02 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. > the files are located in include directories These are directories that **may** contain headers, not directories that **only** contain headers. (Which we mostly expect `-Isystem` to be). For example, many projects keep headers next to sources, and so have sources on

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-02 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler added a comment. I hope this isn't too controversial. After all, the files are located in include directories, so there shouldn't be any random garbage getting picked up. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112996/new/ https://

[PATCH] D112996: [CodeCompletion] Generally consider header files without extension

2021-11-02 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler created this revision. ckandeler added a reviewer: sammccall. ckandeler requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Real-world use case: The Qt framework's headers have the same name as the respective class defined in them, an