[NFC][DwarfDebug] Avoid default capturing when using lambdas
authorDjordje Todorovic <djordje.todorovic@syrmia.com>
Mon, 11 May 2020 07:30:36 +0000 (09:30 +0200)
committerDjordje Todorovic <djordje.todorovic@syrmia.com>
Mon, 11 May 2020 08:02:13 +0000 (10:02 +0200)
commit45e5a32a8bd36836c26778f71accdbccdc770a42
tree8c2c97cf0b17009951577e53e1a30bd0c9032c59
parent507d1eb1cec33ccc2fce0ee7f688e19a42e43990
[NFC][DwarfDebug] Avoid default capturing when using lambdas

It is bad practice to capture by default (via [&] in this case) when
using lambdas, so we should avoid that as much as possible.

This patch fixes that in the getForwardingRegsDefinedByMI
from DwarfDebug module.

Differential Revision: https://reviews.llvm.org/D79616
llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp