llvm/llvm-project

[clang][ExtractAPI] Declaration fragments should show types as shown in the source code.

Open

#61.157 geöffnet am 3. März 2023

Auf GitHub ansehen
 (15 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)C++ (10.782 Forks)batch import
clang:toolinggood first issue

Repository-Metriken

Stars
 (26.378 Stars)
PR-Merge-Metriken
 (Durchschn. Merge 1T 2h) (1.000 gemergte PRs in 30 T)

Beschreibung

For Objective-C APIs that use typedefs, ExtractAPI emits declarations with the original’s type’s name rather than its typedef name.

For example, in:

typedef struct MyStruct * MyTypeDef;

void foo(MyTypeDef x) {}

The declaration for foo is the following:

void foo(struct MyStruct * x)

Rather than:

void foo(MyTypeDef x)

Resolving this issue will align the declaration we generate to the one that’s in the original source code.

Contributor Guide