Skip to content

Commit 54df18e

Browse files
authored
Remove workarounds for old compilers and dependencies (#1234)
1 parent d9b77e5 commit 54df18e

4 files changed

Lines changed: 2 additions & 15 deletions

File tree

test/state/mpt.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,6 @@ class Path
7676
/// The MPT Node.
7777
///
7878
/// The implementation is based on StackTrie from go-ethereum.
79-
// TODO(clang-tidy-17): bug https://github.com/llvm/llvm-project/issues/50006
80-
// NOLINTNEXTLINE(bugprone-reserved-identifier)
8179
class MPTNode
8280
{
8381
static constexpr size_t num_children = 16;

test/state/precompiles.cpp

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -649,12 +649,7 @@ inline constexpr std::array<PrecompileTraits, NumPrecompiles> traits{{
649649

650650
bool is_precompile(evmc_revision rev, const evmc::address& addr) noexcept
651651
{
652-
// Define compile-time constant,
653-
// TODO(clang18): workaround for Clang Analyzer bug, fixed in clang 18.
654-
// https://github.com/llvm/llvm-project/issues/59493.
655-
static constexpr evmc::address address_boundary{stdx::to_underlying(PrecompileId::latest)};
656-
657-
if (evmc::is_zero(addr) || addr > address_boundary)
652+
if (evmc::is_zero(addr) || addr > evmc::address{stdx::to_underlying(PrecompileId::latest)})
658653
return false;
659654

660655
const auto id = addr.bytes[19];

test/state/state.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ StateDiff State::build_diff(evmc_revision rev) const
230230
// Unconditionally report nonce and balance as modified.
231231
// TODO: We don't have information if the balance/nonce has actually changed.
232232
// One option is to just keep the original values. This may be handy for RPC.
233-
// TODO(clang): In old Clang emplace_back without Account doesn't compile.
233+
// TODO(clang): In AppleClang 15 emplace_back without StateDiff::Entry doesn't compile.
234234
// NOLINTNEXTLINE(modernize-use-emplace)
235235
auto& a = diff.modified_accounts.emplace_back(StateDiff::Entry{addr, m.nonce, m.balance});
236236

test/unittests/precompiles_kzg_test.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,6 @@ using namespace evmone::crypto;
1414

1515
namespace
1616
{
17-
// TODO(intx): Add ""_u384.
18-
consteval auto operator""_u384(const char* s)
19-
{
20-
return intx::from_string<intx::uint384>(s);
21-
}
22-
2317
constexpr auto G1_GENERATOR_X =
2418
0x17F1D3A73197D7942695638C4FA9AC0FC3688C4F9774B905A14E3A3F171BAC586C55E83FF97A1AEFFB3AF00ADB22C6BB_u384;
2519
constexpr std::byte ZERO32[32]{};

0 commit comments

Comments
 (0)