retdec
string.h
Go to the documentation of this file.
1 
7 #ifndef RETDEC_LLVMIR2HLL_UTILS_STRING_H
8 #define RETDEC_LLVMIR2HLL_UTILS_STRING_H
9 
10 #include <string>
11 
12 namespace retdec {
13 namespace llvmir2hll {
14 
17 
18 std::string makeIdentifierValid(const std::string &id);
19 
20 std::string getAddressFromName(const std::string &name,
21  const std::string &prefix = "0x");
22 
23 std::string getOffsetFromName(const std::string &name);
24 
25 std::string getAddressFromLabel(const std::string &label,
26  const std::string &labelPrefix,
27  const std::string &addressPrefix = "0x");
28 
30 
31 } // namespace llvmir2hll
32 } // namespace retdec
33 
34 #endif
A library providing API for working with back-end IR.
std::string makeIdentifierValid(const std::string &id)
Replaces invalid characters by valid ones in the given identifier.
Definition: string.cpp:30
std::string getOffsetFromName(const std::string &name)
Returns the offset extracted from the given name.
Definition: string.cpp:125
std::string getAddressFromLabel(const std::string &label, const std::string &labelPrefix, const std::string &addressPrefix="0x")
Tries to extract an address from the given basic block label.
Definition: string.cpp:171
std::string getAddressFromName(const std::string &name, const std::string &prefix="0x")
Returns the address extracted from the given name.
Definition: string.cpp:66
Definition: archive_wrapper.h:19