Skip to content

Commit 376f509

Browse files
committed
address feedback
1 parent c1be3c5 commit 376f509

File tree

4 files changed

+18
-9
lines changed

4 files changed

+18
-9
lines changed

clang/docs/ReleaseNotes.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -586,7 +586,7 @@ Bug Fixes to Attribute Support
586586
``__attribute__((unused))`` are still ignored after the definition, though
587587
this behavior may be relaxed in the future). (#GH135481)
588588

589-
- Clang will warn if a completete type specializes a deprecated partial specialization.
589+
- Clang will warn if a complete type specializes a deprecated partial specialization.
590590
(#GH44496)
591591

592592
Bug Fixes to C++ Support

clang/include/clang/Sema/Sema.h

+7-6
Original file line numberDiff line numberDiff line change
@@ -2385,12 +2385,13 @@ class Sema final : public SemaBase {
23852385
/// potential availability violations.
23862386
sema::FunctionScopeInfo *getCurFunctionAvailabilityContext();
23872387

2388-
void DiagnoseAvailabilityOfDecl(
2389-
NamedDecl *D, ArrayRef<SourceLocation> Locs,
2390-
const ObjCInterfaceDecl *UnknownObjCClass = nullptr,
2391-
bool ObjCPropertyAccess = false,
2392-
bool AvoidPartialAvailabilityChecks = false,
2393-
ObjCInterfaceDecl *ClassReceiver = nullptr);
2388+
void DiagnoseAvailabilityOfDecl(NamedDecl *D, ArrayRef<SourceLocation> Locs,
2389+
const ObjCInterfaceDecl *UnknownObjCClass,
2390+
bool ObjCPropertyAccess,
2391+
bool AvoidPartialAvailabilityChecks,
2392+
ObjCInterfaceDecl *ClassReceiver);
2393+
2394+
void DiagnoseAvailabilityOfDecl(NamedDecl *D, ArrayRef<SourceLocation> Locs);
23942395

23952396
std::pair<AvailabilityResult, const NamedDecl *>
23962397
ShouldDiagnoseAvailabilityOfDecl(const NamedDecl *D, std::string *Message,

clang/lib/Sema/SemaAvailability.cpp

+8
Original file line numberDiff line numberDiff line change
@@ -1145,3 +1145,11 @@ void Sema::DiagnoseAvailabilityOfDecl(NamedDecl *D,
11451145
EmitAvailabilityWarning(*this, Result, D, OffendingDecl, Message, Locs,
11461146
UnknownObjCClass, ObjCPDecl, ObjCPropertyAccess);
11471147
}
1148+
1149+
void Sema::DiagnoseAvailabilityOfDecl(NamedDecl *D,
1150+
ArrayRef<SourceLocation> Locs) {
1151+
DiagnoseAvailabilityOfDecl(D, Locs, /*UnknownObjCClass=*/nullptr,
1152+
/*ObjCPropertyAccess=*/false,
1153+
/*AvoidPartialAvailabilityChecks=*/false,
1154+
/*ClassReceiver=*/nullptr);
1155+
}

clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.deprecated/p1.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,8 @@ template struct B<A>; // expected-note {{requested here}}
7575

7676

7777
namespace GH44496 {
78-
template <class> struct my_template {
79-
using type = void;
78+
template <class> struct my_template {
79+
using type = void;
8080
};
8181

8282
template <class T>

0 commit comments

Comments
 (0)