aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/Object/ELFObjectFileTest.cpp
diff options
context:
space:
mode:
authorAlexey Samsonov <vonosmas@gmail.com>2025-10-31 11:57:08 -0700
committerGitHub <noreply@github.com>2025-10-31 18:57:08 +0000
commit315dfe5865962d8a3d60e21d1fffce5214fe54ef (patch)
treedc1d922963b3a2488851daacd4beabe8b3c9f892 /llvm/unittests/Object/ELFObjectFileTest.cpp
parent4a5692d6b3a6276ef6a8b6a62ef187a16dd3f983 (diff)
downloadllvm-315dfe5865962d8a3d60e21d1fffce5214fe54ef.zip
llvm-315dfe5865962d8a3d60e21d1fffce5214fe54ef.tar.gz
llvm-315dfe5865962d8a3d60e21d1fffce5214fe54ef.tar.bz2
[libc] Templatize strtointeger implementation. (#165884)
* Removes the copy-pasta implementation of wcstointeger, and migrate the wcsto* family of functions to use a template version of strtointeger. * Fixes the out-of-bound read in the original implementation(s) when the entire input string consists of whitespaces (then the sign check can access OOB memory) The code is currently slightly peppered with "if constexpr" statements to distinguish between char and wchar_t. We can probably simplify it in subsequent changes by: * using overrides, so that internal::isalnum() is overriden for both char and wchar_t (since C++ luckily allows us to reuse names). * this wouldn't help for direct comparison with literals - for this as a somewhat ugly workaround like is_char_literal(c, '0', L'0')
Diffstat (limited to 'llvm/unittests/Object/ELFObjectFileTest.cpp')
0 files changed, 0 insertions, 0 deletions