From b7681bef4018ddd99fa4e4784d3de19320d29943 Mon Sep 17 00:00:00 2001 From: Richard Barnes Date: Wed, 3 Jan 2024 14:53:08 -0800 Subject: [PATCH] Remove unused exception parameter from files inc facer/engine/utils/StatsD.cpp Summary: `-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: D51977749 fbshipit-source-id: aab6f8bcb8a0d9273b7894b8e85615d4a31cac86 --- faiss/IndexIDMap.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/faiss/IndexIDMap.cpp b/faiss/IndexIDMap.cpp index 7972bec9a0..02bfbc0553 100644 --- a/faiss/IndexIDMap.cpp +++ b/faiss/IndexIDMap.cpp @@ -266,7 +266,7 @@ void IndexIDMap2Template::reconstruct( typename IndexT::component_t* recons) const { try { this->index->reconstruct(rev_map.at(key), recons); - } catch (const std::out_of_range& e) { + } catch (const std::out_of_range&) { FAISS_THROW_FMT("key %" PRId64 " not found", key); } }