@@ -448,7 +448,7 @@ class TypedInit : public Init {
448448};
449449
450450// / '?' - Represents an uninitialized value.
451- class UnsetInit : public Init {
451+ class UnsetInit final : public Init {
452452 friend detail::RecordKeeperImpl;
453453
454454 // / The record keeper that initialized this Init.
@@ -486,7 +486,7 @@ class UnsetInit : public Init {
486486
487487// Represent an argument.
488488using ArgAuxType = std::variant<unsigned , const Init *>;
489- class ArgumentInit : public Init , public FoldingSetNode {
489+ class ArgumentInit final : public Init, public FoldingSetNode {
490490public:
491491 enum Kind {
492492 Positional,
@@ -638,7 +638,7 @@ class BitsInit final : public TypedInit,
638638};
639639
640640// / '7' - Represent an initialization by a literal integer value.
641- class IntInit : public TypedInit {
641+ class IntInit final : public TypedInit {
642642 int64_t Value;
643643
644644 explicit IntInit (RecordKeeper &RK, int64_t V)
@@ -669,7 +669,7 @@ class IntInit : public TypedInit {
669669};
670670
671671// / "anonymous_n" - Represent an anonymous record name
672- class AnonymousNameInit : public TypedInit {
672+ class AnonymousNameInit final : public TypedInit {
673673 unsigned Value;
674674
675675 explicit AnonymousNameInit (RecordKeeper &RK, unsigned V)
@@ -699,7 +699,7 @@ class AnonymousNameInit : public TypedInit {
699699};
700700
701701// / "foo" - Represent an initialization by a string value.
702- class StringInit : public TypedInit {
702+ class StringInit final : public TypedInit {
703703public:
704704 enum StringFormat {
705705 SF_String, // Format as "text"
@@ -845,7 +845,7 @@ class OpInit : public TypedInit {
845845
846846// / !op (X) - Transform an init.
847847// /
848- class UnOpInit : public OpInit , public FoldingSetNode {
848+ class UnOpInit final : public OpInit, public FoldingSetNode {
849849public:
850850 enum UnaryOp : uint8_t {
851851 TOLOWER,
@@ -908,7 +908,7 @@ class UnOpInit : public OpInit, public FoldingSetNode {
908908};
909909
910910// / !op (X, Y) - Combine two inits.
911- class BinOpInit : public OpInit , public FoldingSetNode {
911+ class BinOpInit final : public OpInit, public FoldingSetNode {
912912public:
913913 enum BinaryOp : uint8_t {
914914 ADD,
@@ -995,7 +995,7 @@ class BinOpInit : public OpInit, public FoldingSetNode {
995995};
996996
997997// / !op (X, Y, Z) - Combine two inits.
998- class TernOpInit : public OpInit , public FoldingSetNode {
998+ class TernOpInit final : public OpInit, public FoldingSetNode {
999999public:
10001000 enum TernaryOp : uint8_t {
10011001 SUBST,
@@ -1144,7 +1144,7 @@ class CondOpInit final : public TypedInit,
11441144};
11451145
11461146// / !foldl (a, b, expr, start, lst) - Fold over a list.
1147- class FoldOpInit : public TypedInit , public FoldingSetNode {
1147+ class FoldOpInit final : public TypedInit, public FoldingSetNode {
11481148private:
11491149 const Init *Start, *List, *A, *B, *Expr;
11501150
@@ -1179,7 +1179,7 @@ class FoldOpInit : public TypedInit, public FoldingSetNode {
11791179};
11801180
11811181// / !isa<type>(expr) - Dynamically determine the type of an expression.
1182- class IsAOpInit : public TypedInit , public FoldingSetNode {
1182+ class IsAOpInit final : public TypedInit, public FoldingSetNode {
11831183private:
11841184 const RecTy *CheckType;
11851185 const Init *Expr;
@@ -1213,7 +1213,7 @@ class IsAOpInit : public TypedInit, public FoldingSetNode {
12131213
12141214// / !exists<type>(expr) - Dynamically determine if a record of `type` named
12151215// / `expr` exists.
1216- class ExistsOpInit : public TypedInit , public FoldingSetNode {
1216+ class ExistsOpInit final : public TypedInit, public FoldingSetNode {
12171217private:
12181218 const RecTy *CheckType;
12191219 const Init *Expr;
@@ -1246,7 +1246,7 @@ class ExistsOpInit : public TypedInit, public FoldingSetNode {
12461246};
12471247
12481248// / 'Opcode' - Represent a reference to an entire variable object.
1249- class VarInit : public TypedInit {
1249+ class VarInit final : public TypedInit {
12501250 const Init *VarName;
12511251
12521252 explicit VarInit (const Init *VN, const RecTy *T)
@@ -1320,7 +1320,7 @@ class VarBitInit final : public TypedInit {
13201320};
13211321
13221322// / AL - Represent a reference to a 'def' in the description
1323- class DefInit : public TypedInit {
1323+ class DefInit final : public TypedInit {
13241324 friend class Record ;
13251325
13261326 const Record *Def;
@@ -1409,7 +1409,7 @@ class VarDefInit final
14091409};
14101410
14111411// / X.Y - Represent a reference to a subfield of a variable
1412- class FieldInit : public TypedInit {
1412+ class FieldInit final : public TypedInit {
14131413 const Init *Rec; // Record we are referring to
14141414 const StringInit *FieldName; // Field we are accessing
14151415
0 commit comments