Commit Graph

5 Commits

Author SHA1 Message Date
Rintaro Ishizaki
b3453c17fe [ClangImporter] Take isCompatibilityAlias() into account in interface printing (#16625)
If the Clang declrations are *types*, canonical declaration in Swift is
imported for newest version of Swift. In interface generation, if the
declaration is versioned and it's imported as a member in either or both
version of Swift, we have to take compatibility typealias into account.

* Fixed 'ClangModuleUnit::getTopLevelDecls' to take isCompatibilityAlias() into account
* Fixed bugs in ClangImporter where member-to-member versioned types aren't properly imported.
  * Fixed 'SwiftDeclConverter::importFullName' to check equality of getEffectiveContext()
  * Fixed 'importer::addEntryToLookupTable' to check equality of getEffectiveContext()
    (moved 'ClangImporter::Implementation::forEachDistinctName' to 'NameImporter')
2018-05-22 13:38:45 +09:00
Ted Kremenek
cc3024d7c5 Swift 4.x (x < 2) names are obsoleted in 4.2, not 5.
In APINotes, when an unversioned name overrides
a previously declared name with a Swift version, if the
previously declared name is guarded under version 4
the obsoleted version should be 4.2, not 5.  In all other
cases, the obsoleted version is the next major Swift
version.

Fixes rdar://problem/39950937
2018-05-09 00:19:42 -07:00
Doug Gregor
c9fa65097e [API Notes] Test SwiftPrivate API notes.
*Clang update required*

Test that rdar://problem/25872038 works for Swift.
2016-04-21 23:37:18 -07:00
Doug Gregor
1899882942 [API Notes] Test API notes for tags and typedefs.
Verifies the Clang-side change for rdar://problem/25365464.

**Clang update required**
2016-03-30 23:37:58 -07:00
Doug Gregor
88d73faba8 [API Notes] Test use of API notes to change the Swift name of an entity.
*Note*: requires Clang update, which adds support for SwiftName.
2016-02-20 22:03:38 -08:00