From 1ae19b9c65f905a65073a3af86f365e60589bf33 Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Fri, 8 Nov 2024 14:37:46 +1000 Subject: [PATCH] region: add union-assignment operator --- cruft/util/region.hpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/cruft/util/region.hpp b/cruft/util/region.hpp index 8e2a227f..36fbf7cb 100644 --- a/cruft/util/region.hpp +++ b/cruft/util/region.hpp @@ -258,6 +258,15 @@ namespace cruft { } + //------------------------------------------------------------------------- + template + region& + operator|= (region &a, region const &b) + { + return a = a | b; + } + + /////////////////////////////////////////////////////////////////////////// /// Construct a region that consists of the overlapping portions of two /// supplied regions.