diff options
author | dos-reis <gdr@axiomatics.org> | 2009-01-07 07:54:17 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2009-01-07 07:54:17 +0000 |
commit | a4baedf72d3abfe9f74ee1dade09a454c0ae7c00 (patch) | |
tree | 315802f081992e649bc4ae09e8b688f5158d41bf /src/algebra/data.spad.pamphlet | |
parent | cd753a762cfc0b7067806c794f463a3636c3918e (diff) | |
download | open-axiom-a4baedf72d3abfe9f74ee1dade09a454c0ae7c00.tar.gz |
* interp/sys-utility.boot (readByteFromFile): Tidy.
(makeByteBuffer): Set fill pointer.
(connectToHostAndPort): Define here.
(readByteFromStreamSocket): Likewise.
(writeByteToStreamSocket): Likewise.
* interp/sys-os.boot (doConnectToHostAndPort): Rename from
connectot$NetworkClientSocket.
(doReadByteFromStreamSocket): Rename from readByteFromStreamSocket.
(doWriteByteToStreamSocket): Rename from writeByteToStreamSocket.
* algebra/net.spad.pamphlet: Use Maybe Byte.
* algebra/data.spad.pamphlet (ByteBuffer): Fix fill pointer thinko.
Diffstat (limited to 'src/algebra/data.spad.pamphlet')
-rw-r--r-- | src/algebra/data.spad.pamphlet | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/algebra/data.spad.pamphlet b/src/algebra/data.spad.pamphlet index d684c59d..a46ab663 100644 --- a/src/algebra/data.spad.pamphlet +++ b/src/algebra/data.spad.pamphlet @@ -81,8 +81,11 @@ ByteBuffer(): Public == Private where ++ setLength!(buf,n) sets the number of active bytes in the ++ `buf'. Error if `n' is more than the capacity. Private == add + makeByteBuffer(n: NonNegativeInteger): % == + makeByteBuffer(n)$Lisp + byteBuffer n == - buf := makeByteBuffer(n)$Lisp + buf := makeByteBuffer n setLength!(buf,0) buf @@ -127,7 +130,7 @@ ByteBuffer(): Public == Private where s construct l == - buf := byteBuffer(#l) + buf := makeByteBuffer(#l) for b in l for i in 0.. repeat buf.i := b buf @@ -135,7 +138,7 @@ ByteBuffer(): Public == Private where concat(x: %, y:%) == nx := #x ny := #y - buf := byteBuffer(nx + ny) + buf := makeByteBuffer(nx + ny) for i in 0..(nx - 1) repeat buf.i := x.i for i in 0..(ny - 1) repeat |