Skip to content

Commit 7415799

Browse files
authored
[Driver][NFC] Make some derived classes of Tool final (#70416)
1 parent 9a091de commit 7415799

26 files changed

+38
-38
lines changed

clang/lib/Driver/ToolChains/AIX.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ namespace tools {
1919
/// Directly call system default assembler and linker.
2020
namespace aix {
2121

22-
class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
22+
class LLVM_LIBRARY_VISIBILITY Assembler final : public Tool {
2323
public:
2424
Assembler(const ToolChain &TC) : Tool("aix::Assembler", "assembler", TC) {}
2525

@@ -31,7 +31,7 @@ class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
3131
const char *LinkingOutput) const override;
3232
};
3333

34-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
34+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
3535
public:
3636
Linker(const ToolChain &TC) : Tool("aix::Linker", "linker", TC) {}
3737

clang/lib/Driver/ToolChains/AMDGPU.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ namespace driver {
2626
namespace tools {
2727
namespace amdgpu {
2828

29-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
29+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
3030
public:
3131
Linker(const ToolChain &TC) : Tool("amdgpu::Linker", "ld.lld", TC) {}
3232
bool isLinkJob() const override { return true; }

clang/lib/Driver/ToolChains/AVR.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ class LLVM_LIBRARY_VISIBILITY AVRToolChain : public Generic_ELF {
4949

5050
namespace tools {
5151
namespace AVR {
52-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
52+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
5353
public:
5454
Linker(const llvm::Triple &Triple, const ToolChain &TC)
5555
: Tool("AVR::Linker", "avr-ld", TC), Triple(Triple) {}

clang/lib/Driver/ToolChains/BareMetal.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ class LLVM_LIBRARY_VISIBILITY StaticLibTool : public Tool {
9898
const char *LinkingOutput) const override;
9999
};
100100

101-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
101+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
102102
public:
103103
Linker(const ToolChain &TC) : Tool("baremetal::Linker", "ld.lld", TC) {}
104104
bool isLinkJob() const override { return true; }

clang/lib/Driver/ToolChains/CSKYToolChain.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class LLVM_LIBRARY_VISIBILITY CSKYToolChain : public Generic_ELF {
4444

4545
namespace tools {
4646
namespace CSKY {
47-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
47+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
4848
public:
4949
Linker(const ToolChain &TC) : Tool("CSKY::Linker", "ld", TC) {}
5050
bool hasIntegratedCPP() const override { return false; }

clang/lib/Driver/ToolChains/CrossWindows.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ namespace driver {
2020
namespace tools {
2121

2222
namespace CrossWindows {
23-
class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
23+
class LLVM_LIBRARY_VISIBILITY Assembler final : public Tool {
2424
public:
2525
Assembler(const ToolChain &TC) : Tool("CrossWindows::Assembler", "as", TC) {}
2626

@@ -32,7 +32,7 @@ class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
3232
const char *LinkingOutput) const override;
3333
};
3434

35-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
35+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
3636
public:
3737
Linker(const ToolChain &TC) : Tool("CrossWindows::Linker", "ld", TC) {}
3838

clang/lib/Driver/ToolChains/Cuda.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ namespace tools {
8181
namespace NVPTX {
8282

8383
// Run ptxas, the NVPTX assembler.
84-
class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
84+
class LLVM_LIBRARY_VISIBILITY Assembler final : public Tool {
8585
public:
8686
Assembler(const ToolChain &TC) : Tool("NVPTX::Assembler", "ptxas", TC) {}
8787

@@ -108,7 +108,7 @@ class LLVM_LIBRARY_VISIBILITY FatBinary : public Tool {
108108
};
109109

110110
// Runs nvlink, which links GPU object files ("cubin" files) into a single file.
111-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
111+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
112112
public:
113113
Linker(const ToolChain &TC) : Tool("NVPTX::Linker", "nvlink", TC) {}
114114

clang/lib/Driver/ToolChains/DragonFly.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ namespace tools {
1919

2020
/// Directly call GNU Binutils assembler and linker
2121
namespace dragonfly {
22-
class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
22+
class LLVM_LIBRARY_VISIBILITY Assembler final : public Tool {
2323
public:
2424
Assembler(const ToolChain &TC)
2525
: Tool("dragonfly::Assembler", "assembler", TC) {}
@@ -32,7 +32,7 @@ class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
3232
const char *LinkingOutput) const override;
3333
};
3434

35-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
35+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
3636
public:
3737
Linker(const ToolChain &TC) : Tool("dragonfly::Linker", "linker", TC) {}
3838

clang/lib/Driver/ToolChains/FreeBSD.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ namespace tools {
1919

2020
/// Directly call GNU Binutils assembler and linker
2121
namespace freebsd {
22-
class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
22+
class LLVM_LIBRARY_VISIBILITY Assembler final : public Tool {
2323
public:
2424
Assembler(const ToolChain &TC)
2525
: Tool("freebsd::Assembler", "assembler", TC) {}
@@ -32,7 +32,7 @@ class LLVM_LIBRARY_VISIBILITY Assembler : public Tool {
3232
const char *LinkingOutput) const override;
3333
};
3434

35-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
35+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
3636
public:
3737
Linker(const ToolChain &TC) : Tool("freebsd::Linker", "linker", TC) {}
3838

clang/lib/Driver/ToolChains/Fuchsia.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class LLVM_LIBRARY_VISIBILITY StaticLibTool : public Tool {
3232
const char *LinkingOutput) const override;
3333
};
3434

35-
class LLVM_LIBRARY_VISIBILITY Linker : public Tool {
35+
class LLVM_LIBRARY_VISIBILITY Linker final : public Tool {
3636
public:
3737
Linker(const ToolChain &TC) : Tool("fuchsia::Linker", "ld.lld", TC) {}
3838

0 commit comments

Comments
 (0)