aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/ADT/StringRefTest.cpp
diff options
context:
space:
mode:
authorThomas Preud'homme <thomas.preudhomme@arm.com>2023-05-16 09:22:01 +0000
committerThomas Preud'homme <thomas.preudhomme@arm.com>2023-05-23 13:52:22 +0100
commit13eb298d5c3c31550fee0c889d3fd3a265450e3d (patch)
tree5b785f0006cee7f2434c625f5b60fcb15e0bf39d /llvm/unittests/ADT/StringRefTest.cpp
parentc37ced7d026e2629aa513f935f0ff46215f7d09e (diff)
downloadllvm-13eb298d5c3c31550fee0c889d3fd3a265450e3d.zip
llvm-13eb298d5c3c31550fee0c889d3fd3a265450e3d.tar.gz
llvm-13eb298d5c3c31550fee0c889d3fd3a265450e3d.tar.bz2
Turn unreachable error into assert
Function valueFromStringRepr() throws an error on missing 0x prefix when parsing a number string into a value. However, getWildcardRegex() already ensures that only text with the 0x prefix will match and be parsed, making that error throwing code dead code. This commit turn the code into an assert and remove the unit tests exercising that test accordingly. Reviewed By: jhenderson Differential Revision: https://reviews.llvm.org/D150797
Diffstat (limited to 'llvm/unittests/ADT/StringRefTest.cpp')
0 files changed, 0 insertions, 0 deletions