From b386f4e5e24e9c618c2b0660b3327142229569e7 Mon Sep 17 00:00:00 2001
From: Mark Olesen <Mark.Olesen@Germany>
Date: Mon, 9 Mar 2009 16:35:45 +0100
Subject: [PATCH] Switch: make operator= pass-thru value

---
 src/OpenFOAM/primitives/bools/Switch/Switch.H | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/OpenFOAM/primitives/bools/Switch/Switch.H b/src/OpenFOAM/primitives/bools/Switch/Switch.H
index b37e2bbb403..4eaa2dd12b5 100644
--- a/src/OpenFOAM/primitives/bools/Switch/Switch.H
+++ b/src/OpenFOAM/primitives/bools/Switch/Switch.H
@@ -176,9 +176,10 @@ public:
         }
 
         //- Assignment from bool
-        void operator=(const bool b)
+        const Switch& operator=(const bool b)
         {
             switch_ = (b ? Switch::TRUE : Switch::FALSE);
+            return *this;
         }
 
 
-- 
GitLab