From 3c236c7c3f92cb276485b3d7bae04ecd5d36bc08 Mon Sep 17 00:00:00 2001 From: Richard Barnes Date: Thu, 7 Nov 2024 15:48:48 -0800 Subject: [PATCH] Remove unused-variable in multipy/runtime/interpreter/interpreter_impl.cpp +1 Summary: LLVM-15 has a warning `-Wunused-variable` which we treat as an error because it's so often diagnostic of a code issue. Unused variables can compromise readability or, worse, performance. This diff either (a) removes an unused variable and, possibly, it's associated code or (b) qualifies the variable with `[[maybe_unused]]`. - If you approve of this diff, please use the "Accept & Ship" button :-) Differential Revision: D65282886 --- multipy/runtime/interpreter/interpreter_impl.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/multipy/runtime/interpreter/interpreter_impl.cpp b/multipy/runtime/interpreter/interpreter_impl.cpp index 3d5f38e1..2a27b01f 100644 --- a/multipy/runtime/interpreter/interpreter_impl.cpp +++ b/multipy/runtime/interpreter/interpreter_impl.cpp @@ -360,7 +360,6 @@ struct __attribute__((visibility("hidden"))) ConcreteInterpreterObj torch::deploy::Obj attr(const char* attribute) override { MULTIPY_SAFE_RETHROW { - bool a = hasattr(attribute); py::object pyObj = getPyObject().attr(attribute); std::shared_ptr cObj = std::make_shared(pyObj, owningSession_);