mirror of
https://github.com/facebookresearch/faiss.git
synced 2025-06-03 21:54:02 +08:00
Remove unused exception parameter from faiss/impl/ResultHandler.h (#4243)
Summary: Pull Request resolved: https://github.com/facebookresearch/faiss/pull/4243 `-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: dtolnay Differential Revision: D71290934 fbshipit-source-id: f5e47eed369a9a024cc1e16a23acafa49f75b651
This commit is contained in:
parent
fec7ce96fb
commit
9e808d4ea1
@ -534,7 +534,7 @@ struct RangeSearchBlockResultHandler : BlockResultHandler<C, use_sel> {
|
||||
try {
|
||||
// finalize the partial result
|
||||
pres.finalize();
|
||||
} catch (const faiss::FaissException& e) {
|
||||
} catch ([[maybe_unused]] const faiss::FaissException& e) {
|
||||
// Do nothing if allocation fails in finalizing partial results.
|
||||
#ifndef NDEBUG
|
||||
std::cerr << e.what() << std::endl;
|
||||
@ -598,7 +598,7 @@ struct RangeSearchBlockResultHandler : BlockResultHandler<C, use_sel> {
|
||||
if (partial_results.size() > 0) {
|
||||
RangeSearchPartialResult::merge(partial_results);
|
||||
}
|
||||
} catch (const faiss::FaissException& e) {
|
||||
} catch ([[maybe_unused]] const faiss::FaissException& e) {
|
||||
// Do nothing if allocation fails in merge.
|
||||
#ifndef NDEBUG
|
||||
std::cerr << e.what() << std::endl;
|
||||
|
Loading…
x
Reference in New Issue
Block a user