| 544 | } |
| 545 | |
| 546 | static MacroSegment * |
| 547 | getMacroSegmentFromNestedMacro(Macro *nestedMacro, |
| 548 | const std::vector<MacroEdit *> ¯oEdits) |
| 549 | { |
| 550 | for (const auto ¯oEdit : macroEdits) { |
| 551 | const auto macro = macroEdit->GetMacro(); |
| 552 | if (!macro) { |
| 553 | continue; |
| 554 | } |
| 555 | for (const auto &action : macro->Actions()) { |
| 556 | if (isMatchingNestedMacroAction(action.get(), |
| 557 | nestedMacro)) { |
| 558 | return action.get(); |
| 559 | } |
| 560 | } |
| 561 | for (const auto &action : macro->ElseActions()) { |
| 562 | if (isMatchingNestedMacroAction(action.get(), |
| 563 | nestedMacro)) { |
| 564 | return action.get(); |
| 565 | } |
| 566 | } |
| 567 | } |
| 568 | return nullptr; |
| 569 | } |
| 570 | |
| 571 | void TempVariableSelection::PopulateSelection() |
| 572 | { |
no test coverage detected