Merge remote-tracking branch 'origin/master' into master-next

This commit is contained in:
swift_jenkins
2020-05-11 11:19:10 -07:00
4 changed files with 9 additions and 5 deletions

View File

@@ -1145,6 +1145,8 @@ public:
// Decls with @_alwaysEmitIntoClient aren't required to have an
// @available attribute.
if (!Ctx.getOpts().SkipOSCheck &&
DeclAttribute::canAttributeAppearOnDeclKind(DeclAttrKind::DAK_Available,
D->getDeclKind()) &&
!D->getIntroducingVersion().hasOSAvailability() &&
!D->hasDeclAttribute(DeclAttrKind::DAK_AlwaysEmitIntoClient)) {
D->emitDiag(D->getLoc(), diag::new_decl_without_intro);