File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -1796,14 +1796,13 @@ const Init *TernOpInit::Fold(const Record *CurRec) const {
1796
1796
if (LHSs && MHSs && RHSs) {
1797
1797
std::string Val = RHSs->getValue ().str ();
1798
1798
1799
- StringRef::size_type found;
1800
- StringRef::size_type idx = 0 ;
1799
+ std::string::size_type Idx = 0 ;
1801
1800
while (true ) {
1802
- found = StringRef ( Val) .find (LHSs->getValue (), idx );
1803
- if (found == StringRef ::npos)
1801
+ std::string::size_type Found = Val.find (LHSs->getValue (), Idx );
1802
+ if (Found == std::string ::npos)
1804
1803
break ;
1805
- Val.replace (found , LHSs->getValue ().size (), MHSs->getValue ().str ());
1806
- idx = found + MHSs->getValue ().size ();
1804
+ Val.replace (Found , LHSs->getValue ().size (), MHSs->getValue ().str ());
1805
+ Idx = Found + MHSs->getValue ().size ();
1807
1806
}
1808
1807
1809
1808
return StringInit::get (RK, Val);
You can’t perform that action at this time.
0 commit comments