mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Also make the titles and one line summaries a little more consistent (at least for diagnsotic groups and upcoming language features, haven't gone through the educational notes).
20 lines
632 B
Markdown
20 lines
632 B
Markdown
# Imported Clang declaration warnings (ClangDeclarationImport)
|
||
|
||
Covers all warnings related to malformed APIs that are imported into Swift from C, C++, and Obj-C headers.
|
||
|
||
|
||
## Overview
|
||
|
||
As one example of a potential malformed API diagnostic, suppose a Clang module dependency contained the following declaration:
|
||
|
||
```
|
||
typedef int NotificationIdentifier
|
||
__attribute__((swift_name("Notification.Identifier")))
|
||
```
|
||
|
||
The Swift compiler would emit the following warning if no type named `Notification` could be found:
|
||
|
||
```
|
||
warning: imported declaration 'NotificationIdentifier' could not be mapped to 'Notification.Identifier’
|
||
```
|