1

I have such codes:

int flag1 = GetWidget(widget);
flag1.append(widget);
delete widget;

I'm willing to swap every flag1 and widget in the whole text, i.e.:

int widget = GetWidget(flag1);
widget.append(flag1);
delete flag1;

I've tried replace every flag1 with an unused word (like dfgsergwer) and then replace widget to flag1 and finally replace dfgsergwer to widget, but it seems not intuitive.

Any way to do it elegantly?

Mactarvish
  • 11
  • 1

0 Answers0