From c8c57fc6eaf4cb05d9656bab746e138cab11f4bf Mon Sep 17 00:00:00 2001
From: Jan Travnicek <Jan.Travnicek@fit.cvut.cz>
Date: Tue, 7 Mar 2017 10:06:10 +0100
Subject: [PATCH] fix -Werror=maybe-uninitialized on gcc6

---
 alib2std/src/extensions/variant.hpp | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/alib2std/src/extensions/variant.hpp b/alib2std/src/extensions/variant.hpp
index a422fcc653..b6027894bb 100644
--- a/alib2std/src/extensions/variant.hpp
+++ b/alib2std/src/extensions/variant.hpp
@@ -170,7 +170,10 @@ protected:
 	type_id_hash_code type_id;
 	data_t data;
 
-	variant_base( type_id_hash_code id ) : type_id ( id ) { }
+	variant_base( type_id_hash_code id ) : type_id ( id ) {
+		// just to make the -Werror=maybe-uninitialized go away
+		std::memset( & data, 0, data_size );
+	}
 };
 
 template<typename ST, typename AT, typename F, typename... Ts>
-- 
GitLab