From 9f115c3dea8acb1295bcaeec5668c9816541ed90 Mon Sep 17 00:00:00 2001 From: Eryn Wells Date: Thu, 14 Apr 2016 01:36:41 -0400 Subject: [PATCH] Add Bitmap::isFull() --- src/kstd/Bitmap.hh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/kstd/Bitmap.hh b/src/kstd/Bitmap.hh index 981d9c4..82e0696 100644 --- a/src/kstd/Bitmap.hh +++ b/src/kstd/Bitmap.hh @@ -85,11 +85,19 @@ struct Bitmap mBitmap = ~(0); } + bool + isFull() + const + { + return mBitmap != ~(0); + } + private: FieldType mBitmap; inline bool isValid(usize bit) + const { return bit >= 0 && bit < Bitmap::length; }