From 1047c2517de8c69ff3dd4621aa341df1ecdb992c Mon Sep 17 00:00:00 2001 From: Alexander Gavrilov Date: Sun, 12 Feb 2012 17:44:19 +0400 Subject: [PATCH] Add size-defining constructors for BitArray. --- library/include/BitArray.h | 7 +++++++ library/xml | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/library/include/BitArray.h b/library/include/BitArray.h index 0389df796..cc1ddc19f 100644 --- a/library/include/BitArray.h +++ b/library/include/BitArray.h @@ -46,6 +46,13 @@ namespace DFHack free(bits); } + explicit BitArray(T last) : bits(NULL), size(0) { + extend(last); + } + explicit BitArray(unsigned last) : bits(NULL), size(0) { + extend(T(last)); + } + void clear_all ( void ) { if(bits) diff --git a/library/xml b/library/xml index 2444f376e..7fcdca717 160000 --- a/library/xml +++ b/library/xml @@ -1 +1 @@ -Subproject commit 2444f376e32783c9f7a7bf103b209e256e64ed80 +Subproject commit 7fcdca71787d7e998cec2f771999e722609093f1