Skip to content

Commit 336fabf

Browse files
committed
[AutoBump] Merge with e0e67a6 (Feb 17)
2 parents e751f07 + e0e67a6 commit 336fabf

File tree

543 files changed

+12715
-3971
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

543 files changed

+12715
-3971
lines changed

.ci/metrics/metrics.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ class JobMetrics:
2424
status: int
2525
created_at_ns: int
2626
workflow_id: int
27+
workflow_name: str
2728

2829

2930
@dataclass
@@ -199,6 +200,7 @@ def get_per_workflow_metrics(
199200
job_result,
200201
created_at_ns,
201202
workflow_run.id,
203+
workflow_run.name,
202204
)
203205
)
204206

@@ -278,7 +280,7 @@ def main():
278280
for workflow_metric in reversed(current_metrics):
279281
if isinstance(workflow_metric, JobMetrics):
280282
workflows_to_track[
281-
workflow_metric.job_name
283+
workflow_metric.workflow_name
282284
] = workflow_metric.workflow_id
283285

284286
time.sleep(SCRAPE_INTERVAL_SECONDS)

clang-tools-extra/clang-tidy/bugprone/VirtualNearMissCheck.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -179,15 +179,15 @@ static bool checkOverrideByDerivedMethod(const CXXMethodDecl *BaseMD,
179179

180180
bool VirtualNearMissCheck::isPossibleToBeOverridden(
181181
const CXXMethodDecl *BaseMD) {
182-
auto Iter = PossibleMap.find(BaseMD);
183-
if (Iter != PossibleMap.end())
182+
auto [Iter, Inserted] = PossibleMap.try_emplace(BaseMD);
183+
if (!Inserted)
184184
return Iter->second;
185185

186186
bool IsPossible = !BaseMD->isImplicit() && !isa<CXXConstructorDecl>(BaseMD) &&
187187
!isa<CXXDestructorDecl>(BaseMD) && BaseMD->isVirtual() &&
188188
!BaseMD->isOverloadedOperator() &&
189189
!isa<CXXConversionDecl>(BaseMD);
190-
PossibleMap[BaseMD] = IsPossible;
190+
Iter->second = IsPossible;
191191
return IsPossible;
192192
}
193193

clang-tools-extra/clang-tidy/modernize/DeprecatedHeadersCheck.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -199,10 +199,10 @@ void IncludeModernizePPCallbacks::InclusionDirective(
199199
// 2. Insert `using namespace std;` to the beginning of TU.
200200
// 3. Do nothing and let the user deal with the migration himself.
201201
SourceLocation DiagLoc = FilenameRange.getBegin();
202-
if (CStyledHeaderToCxx.count(FileName) != 0) {
203-
IncludesToBeProcessed.emplace_back(
204-
IncludeMarker{CStyledHeaderToCxx[FileName], FileName,
205-
FilenameRange.getAsRange(), DiagLoc});
202+
if (auto It = CStyledHeaderToCxx.find(FileName);
203+
It != CStyledHeaderToCxx.end()) {
204+
IncludesToBeProcessed.emplace_back(IncludeMarker{
205+
It->second, FileName, FilenameRange.getAsRange(), DiagLoc});
206206
} else if (DeleteHeaders.count(FileName) != 0) {
207207
IncludesToBeProcessed.emplace_back(
208208
// NOLINTNEXTLINE(modernize-use-emplace) - false-positive

clang/docs/ReleaseNotes.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -270,6 +270,10 @@ Code Completion
270270
Static Analyzer
271271
---------------
272272

273+
- Clang currently support extending lifetime of object bound to
274+
reference members of aggregates in CFG and ExprEngine, that are
275+
created from default member initializer.
276+
273277
New features
274278
^^^^^^^^^^^^
275279

clang/include/clang/AST/Redeclarable.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,8 +114,6 @@ class Redeclarable {
114114

115115
bool isFirst() const {
116116
return isa<KnownLatest>(Link) ||
117-
// FIXME: 'template' is required on the next line due to an
118-
// apparent clang bug.
119117
isa<UninitializedLatest>(cast<NotKnownLatest>(Link));
120118
}
121119

clang/include/clang/Basic/DiagnosticSemaKinds.td

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12626,6 +12626,9 @@ def err_hlsl_pointers_unsupported : Error<
1262612626
"%select{pointers|references}0 are unsupported in HLSL">;
1262712627
def err_hlsl_missing_resource_class : Error<"HLSL resource needs to have [[hlsl::resource_class()]] attribute">;
1262812628
def err_hlsl_attribute_needs_intangible_type: Error<"attribute %0 can be used only on HLSL intangible type %1">;
12629+
def err_hlsl_incorrect_num_initializers: Error<
12630+
"too %select{few|many}0 initializers in list for type %1 "
12631+
"(expected %2 but found %3)">;
1262912632

1263012633
def err_hlsl_operator_unsupported : Error<
1263112634
"the '%select{&|*|->}0' operator is unsupported in HLSL">;

clang/include/clang/Sema/SemaHLSL.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@
2626
namespace clang {
2727
class AttributeCommonInfo;
2828
class IdentifierInfo;
29+
class InitializedEntity;
30+
class InitializationKind;
2931
class ParsedAttr;
3032
class Scope;
3133
class VarDecl;
@@ -149,6 +151,9 @@ class SemaHLSL : public SemaBase {
149151

150152
QualType getInoutParameterType(QualType Ty);
151153

154+
bool TransformInitList(const InitializedEntity &Entity,
155+
const InitializationKind &Kind, InitListExpr *Init);
156+
152157
private:
153158
// HLSL resource type attributes need to be processed all at once.
154159
// This is a list to collect them.

clang/include/clang/Serialization/ASTWriter.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -751,9 +751,6 @@ class ASTWriter : public ASTDeserializationListener,
751751
/// Get the unique number used to refer to the given macro.
752752
serialization::MacroID getMacroRef(MacroInfo *MI, const IdentifierInfo *Name);
753753

754-
/// Determine the ID of an already-emitted macro.
755-
serialization::MacroID getMacroID(MacroInfo *MI);
756-
757754
uint32_t getMacroDirectivesOffset(const IdentifierInfo *Name);
758755

759756
/// Emit a reference to a type.

clang/lib/AST/ByteCode/Compiler.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2707,7 +2707,8 @@ bool Compiler<Emitter>::VisitMaterializeTemporaryExpr(
27072707

27082708
// For everyhing else, use local variables.
27092709
if (SubExprT) {
2710-
unsigned LocalIndex = allocateLocalPrimitive(E, *SubExprT, /*IsConst=*/true,
2710+
bool IsConst = SubExpr->getType().isConstQualified();
2711+
unsigned LocalIndex = allocateLocalPrimitive(E, *SubExprT, IsConst,
27112712
/*IsExtended=*/true);
27122713
if (!this->visit(SubExpr))
27132714
return false;
@@ -3028,7 +3029,7 @@ bool Compiler<Emitter>::VisitCXXConstructExpr(const CXXConstructExpr *E) {
30283029

30293030
size_t NumElems = CAT->getZExtSize();
30303031
const Function *Func = getFunction(E->getConstructor());
3031-
if (!Func || !Func->isConstexpr())
3032+
if (!Func)
30323033
return false;
30333034

30343035
// FIXME(perf): We're calling the constructor once per array element here,

clang/lib/AST/ByteCode/Descriptor.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,7 @@ struct Descriptor final {
274274

275275
void dump() const;
276276
void dump(llvm::raw_ostream &OS) const;
277+
void dumpFull(unsigned Offset = 0, unsigned Indent = 0) const;
277278
};
278279

279280
/// Bitfield tracking the initialisation status of elements of primitive arrays.

0 commit comments

Comments
 (0)