[PATCH] D70359: [clangd] Show values of more expressions on hover
liu hui via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Nov 18 01:47:21 PST 2019
lh123 added inline comments.
================
Comment at: clang-tools-extra/clangd/Hover.cpp:423
+ // - certain expressions (sizeof etc)
+ // - built-in types
}
----------------
sammccall wrote:
> lh123 wrote:
> > I think we should also support hover on literal.
> sure - can you explain what you'd like to see/when you'd expect it to be useful?
such as:
1. Hovering on "abc" shows char[4], we can get the length information of the string.
2. Get actual type for user-defined literal types.
```c++
struct foo {};
struct foo {};
foo operator""_foo(unsigned long long v) { return {}; }
int main() {
1_foo;
}
```
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D70359/new/
https://reviews.llvm.org/D70359
More information about the cfe-commits
mailing list