From 0bde2f5571091cfbfb1f060807dd1db909dad158 Mon Sep 17 00:00:00 2001
From: Kilian Weishaupt <kilian.weishaupt@iws.uni-stuttgart.de>
Date: Wed, 4 Apr 2018 17:50:46 +0200
Subject: [PATCH] [components][base] Make more methods constexpr

---
 dumux/material/components/base.hh | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/dumux/material/components/base.hh b/dumux/material/components/base.hh
index afc1812c87..d074a7d2b2 100644
--- a/dumux/material/components/base.hh
+++ b/dumux/material/components/base.hh
@@ -76,7 +76,7 @@ public:
      * \brief The molar mass in \f$\mathrm{[kg/mol]}\f$ of the component.
      */
     template<class C = Implementation>
-    static Scalar molarMass()
+    static constexpr Scalar molarMass()
     {
         static_assert(AlwaysFalse<C>::value, "Mandatory function not implemented: molarMass()");
         DUNE_THROW(Dune::NotImplemented, "molarMass()");
@@ -86,7 +86,7 @@ public:
      * \brief Returns the critical temperature in \f$\mathrm{[K]}\f$ of the component.
      */
     template<class C = Implementation>
-    static Scalar criticalTemperature()
+    static constexpr Scalar criticalTemperature()
     {
         static_assert(AlwaysFalse<C>::value, "Mandatory function not implemented: criticalTemperature()");
         DUNE_THROW(Dune::NotImplemented, "criticalTemperature()");
@@ -96,7 +96,7 @@ public:
      * \brief Returns the critical pressure in \f$\mathrm{[Pa]}\f$ of the component.
      */
     template<class C = Implementation>
-    static Scalar criticalPressure()
+    static constexpr Scalar criticalPressure()
     {
         static_assert(AlwaysFalse<C>::value, "Mandatory function not implemented: criticalPressure()");
         DUNE_THROW(Dune::NotImplemented, "criticalPressure()");
@@ -106,7 +106,7 @@ public:
      * \brief Returns the temperature in \f$\mathrm{[K]}\f$ at the component's triple point.
      */
     template<class C = Implementation>
-    static Scalar tripleTemperature()
+    static constexpr Scalar tripleTemperature()
     {
         static_assert(AlwaysFalse<C>::value, "Mandatory function not implemented: tripleTemperature()");
         DUNE_THROW(Dune::NotImplemented, "tripleTemperature()");
@@ -116,7 +116,7 @@ public:
      * \brief Returns the pressure in \f$\mathrm{[Pa]}\f$ at the component's triple point.
      */
     template<class C = Implementation>
-    static Scalar triplePressure()
+    static constexpr Scalar triplePressure()
     {
         static_assert(AlwaysFalse<C>::value, "Mandatory function not implemented: triplePressure()");
         DUNE_THROW(Dune::NotImplemented, "triplePressure()");
-- 
GitLab