mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-15 22:28:18 +00:00
Don't create a whole new string just to copy the elements into it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52785 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -231,11 +231,9 @@ public:
|
|||||||
}
|
}
|
||||||
virtual void Apply(std::string &Field) {
|
virtual void Apply(std::string &Field) {
|
||||||
Constant *C = CI->getOperand(I++);
|
Constant *C = CI->getOperand(I++);
|
||||||
std::string S;
|
// Fills in the string if it succeeds
|
||||||
if (GetConstantStringInfo(C, S))
|
if (!GetConstantStringInfo(C, Field))
|
||||||
Field = S;
|
Field.clear();
|
||||||
else
|
|
||||||
Field = "";
|
|
||||||
}
|
}
|
||||||
virtual void Apply(DebugInfoDesc *&Field) {
|
virtual void Apply(DebugInfoDesc *&Field) {
|
||||||
Constant *C = CI->getOperand(I++);
|
Constant *C = CI->getOperand(I++);
|
||||||
|
Reference in New Issue
Block a user