Skip to content

Commit

Permalink
Fix MSVC build with checked iterators (#1085)
Browse files Browse the repository at this point in the history
  • Loading branch information
can-leh-emmtrix authored Sep 3, 2024
1 parent cdf00c6 commit f8ac3a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion llvm_util/llvm2alive.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1916,7 +1916,7 @@ class llvm2alive_ : public llvm::InstVisitor<llvm2alive_, unique_ptr<Instr>> {
const char *chrs = name.data();
char *end_ptr;
auto numeric_id = strtoul(chrs, &end_ptr, 10);
if (end_ptr != &*name.end())
if (end_ptr != chrs + name.size())
return M->getGlobalVariable(name, true);
else {
auto itr = M->global_begin(), end = M->global_end();
Expand Down

0 comments on commit f8ac3a2

Please sign in to comment.