aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.Memory/Range/MemoryRange.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Ryujinx.Memory/Range/MemoryRange.cs')
-rw-r--r--src/Ryujinx.Memory/Range/MemoryRange.cs14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/Ryujinx.Memory/Range/MemoryRange.cs b/src/Ryujinx.Memory/Range/MemoryRange.cs
index 7465fbcb..c7ee6db2 100644
--- a/src/Ryujinx.Memory/Range/MemoryRange.cs
+++ b/src/Ryujinx.Memory/Range/MemoryRange.cs
@@ -57,5 +57,19 @@
return thisAddress < otherEndAddress && otherAddress < thisEndAddress;
}
+
+ /// <summary>
+ /// Returns a string summary of the memory range.
+ /// </summary>
+ /// <returns>A string summary of the memory range</returns>
+ public override string ToString()
+ {
+ if (Address == ulong.MaxValue)
+ {
+ return $"[Unmapped 0x{Size:X}]";
+ }
+
+ return $"[0x{Address:X}, 0x{EndAddress:X})";
+ }
}
}