From 7319996e9599af847052c7ddfc4e1b23f7a1cf34 Mon Sep 17 00:00:00 2001
From: Simon Praetorius <simon.praetorius@tu-dresden.de>
Date: Fri, 12 Apr 2024 11:09:53 +0200
Subject: [PATCH] Do not return a reference to a local variable in
 CoordsGridFunction

---
 amdis/gridfunctions/CoordsGridFunction.hpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/amdis/gridfunctions/CoordsGridFunction.hpp b/amdis/gridfunctions/CoordsGridFunction.hpp
index ed657d09..2512f186 100644
--- a/amdis/gridfunctions/CoordsGridFunction.hpp
+++ b/amdis/gridfunctions/CoordsGridFunction.hpp
@@ -44,7 +44,7 @@ namespace AMDiS
       struct Derivative
       {
         template <class T, int N>
-        Dune::DiagonalMatrix<T, N> const& operator()(Dune::FieldVector<T, N> const& /*x*/) const
+        Dune::DiagonalMatrix<T, N> operator()(Dune::FieldVector<T, N> const& /*x*/) const
         {
           return Dune::DiagonalMatrix<T,N>{T(1)};
         }
-- 
GitLab