summary refs log tree commit diff
path: root/resources/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'resources/src/lib.rs')
-rw-r--r--resources/src/lib.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/resources/src/lib.rs b/resources/src/lib.rs
index cf36cc1..6195e91 100644
--- a/resources/src/lib.rs
+++ b/resources/src/lib.rs
@@ -46,6 +46,8 @@ pub enum Error {
     OutOfSpace,
     PoolOverflow { base: u64, size: u64 },
     PoolSizeZero,
+    RegionOverlap { base: u64, size: u64 },
+    BadAlloc(Alloc),
 }
 
 pub type Result<T> = std::result::Result<T, Error>;
@@ -64,6 +66,10 @@ impl Display for Error {
             OutOfSpace => write!(f, "Out of space"),
             PoolOverflow { base, size } => write!(f, "base={} + size={} overflows", base, size),
             PoolSizeZero => write!(f, "Pool cannot have size of 0"),
+            RegionOverlap { base, size } => {
+                write!(f, "Overlapping region base={} size={}", base, size)
+            }
+            BadAlloc(tag) => write!(f, "Alloc does not exists: {:?}", tag),
         }
     }
 }