Skip to content

Commit 40522e5

Browse files
committed
[vpr][analysis] capture vars by reference in lambda
1 parent b625d58 commit 40522e5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

vpr/src/analysis/timing_reports.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ static t_bb get_net_bounding_box(const AtomNetId atom_net_id) {
3030
const auto& rr_graph = g_vpr_ctx.device().rr_graph;
3131

3232
// Lambda to get the bounding box of a route tree
33-
auto route_tree_bb = [](const RRGraphView& rr_graph, const RouteTree& route_tree) {
33+
auto route_tree_bb = [&](const RouteTree& route_tree) {
3434
t_bb bb;
3535

3636
// Set the initial bounding box to the root node's location
@@ -70,7 +70,7 @@ static t_bb get_net_bounding_box(const AtomNetId atom_net_id) {
7070
const auto& route_tree = route_trees[atom_net_id];
7171
if (!route_tree)
7272
return t_bb();
73-
return route_tree_bb(rr_graph, *route_tree);
73+
return route_tree_bb(*route_tree);
7474
} else {
7575
// If two-stage router is used, we need to first get the cluster net id
7676
// corresponding to the atom net and then get the bounding box of the net
@@ -87,7 +87,7 @@ static t_bb get_net_bounding_box(const AtomNetId atom_net_id) {
8787
const auto& route_tree = route_trees[clb_net_id];
8888
if (!route_tree)
8989
continue;
90-
bbs.push_back(route_tree_bb(rr_graph, *route_tree));
90+
bbs.push_back(route_tree_bb(*route_tree));
9191
}
9292
if (bbs.empty()) {
9393
return t_bb();

0 commit comments

Comments
 (0)