Skip to content

Commit 1752b7b

Browse files
committed
[clang][Interp][NFC] Apply some clang-tidy suggestions
Remove unused includes and don't use an else after a return.
1 parent 25871b3 commit 1752b7b

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

clang/lib/AST/Interp/InterpFrame.h

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@
1515

1616
#include "Frame.h"
1717
#include "Program.h"
18-
#include <cstdint>
19-
#include <vector>
2018

2119
namespace clang {
2220
namespace interp {
@@ -85,11 +83,9 @@ class InterpFrame final : public Frame {
8583
/// Returns the value of an argument.
8684
template <typename T> const T &getParam(unsigned Offset) const {
8785
auto Pt = Params.find(Offset);
88-
if (Pt == Params.end()) {
86+
if (Pt == Params.end())
8987
return stackRef<T>(Offset);
90-
} else {
91-
return Pointer(reinterpret_cast<Block *>(Pt->second.get())).deref<T>();
92-
}
88+
return Pointer(reinterpret_cast<Block *>(Pt->second.get())).deref<T>();
9389
}
9490

9591
/// Mutates a local copy of a parameter.

0 commit comments

Comments
 (0)