auto function parameter not reported as CXType_Auto
- Dominant language
- LLVM
- Stars
- 40.5k
- Forks
- 18.7k
- PR merge metrics
- PR metrics pending
Description
with the function:
`int bar(auto p){};`
using the C api,
- `auto` is reported as a `TypeRef` with kind `unexposed`
- `p` is reported as `ParmDecl` with kind `unexposed`
I believe it should be only reporting `p` as `ParmDecl` with type `Auto` ( `CXType_Auto` in Index.h), not visiting the "auto" keyword at all. (Same as happens with `VarDecl` in the case of `auto i = 42` )
Contributor guide
Research direction
Start by tracing how the C API represents the `auto` function parameter, using `Index.h` and the reported `TypeRef` and `ParmDecl` nodes as entry points. Compare this with the existing `VarDecl` handling for `auto i = 42`. Done means the parameter is reported as `ParmDecl` with type `CXType_Auto`, without a separate `auto` keyword node.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, cpp
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100