Skip to content

Commit

Permalink
Remove unused exception parameter from hbt/src/perf_event/PerPerfEven…
Browse files Browse the repository at this point in the history
…tsGroupBase.h (#270)

Summary:
Pull Request resolved: #270

`-Wunused-exception-parameter` has identified an unused exception parameter. This diff removes it.

This:
```
try {
    ...
} catch (exception& e) {
    // no use of e
}
```
should instead be written as
```
} catch (exception&) {
```

If the code compiles, this is safe to land.

Reviewed By: dmm-fb

Differential Revision: D58830840
  • Loading branch information
r-barnes authored and facebook-github-bot committed Jun 21, 2024
1 parent 37fb98d commit 85b165d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hbt/src/perf_event/PerPerfEventsGroupBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class PerPerfEventsGroupBase {
for (auto& [_, gen] : generators_) {
gen->enable(reset);
}
} catch (std::exception& /*e*/) {
} catch (std::exception&) {
for (auto& [_, gen] : generators_) {
if (gen->isEnabled()) {
gen->disable();
Expand Down

0 comments on commit 85b165d

Please sign in to comment.