projects
/
Mograsim.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Made Memories look more like other components
[Mograsim.git]
/
net.mograsim.machine
/
src
/
net
/
mograsim
/
machine
/
Memory.java
diff --git
a/net.mograsim.machine/src/net/mograsim/machine/Memory.java
b/net.mograsim.machine/src/net/mograsim/machine/Memory.java
index
58798c3
..
77c0d48
100644
(file)
--- a/
net.mograsim.machine/src/net/mograsim/machine/Memory.java
+++ b/
net.mograsim.machine/src/net/mograsim/machine/Memory.java
@@
-19,7
+19,7
@@
public interface Memory<T>
public default long size()
{
MemoryDefinition def = getDefinition();
public default long size()
{
MemoryDefinition def = getDefinition();
- return Long.max(0, def.getMaximalAddress() - def.getMinimalAddress());
+ return Long.max(0, def.getMaximalAddress() - def.getMinimalAddress()
+ 1
);
}
/**
}
/**