Change `write-bytecode' to accept a bytevector.
authorLudovic Courtès <ludo@gnu.org>
Fri, 5 Feb 2010 10:11:56 +0000 (11:11 +0100)
committerLudovic Courtès <ludo@gnu.org>
Tue, 9 Feb 2010 23:40:01 +0000 (00:40 +0100)
commitbde92e6b3bbd15c7abaf29bc0557041b88df8d74
tree3e40524196deb02ba38460cc32be04bc1cb4a710
parent0c368d2b2811fb856c9551e7ad217f8e5636024f
Change `write-bytecode' to accept a bytevector.

* module/language/assembly/compile-bytecode.scm (write-bytecode):
  Replace the WRITE-BYTE and GET-ADDR parameters with PORT.  New ADDRESS
  and EMIT-OPCODE? parameters.  Callers updated.
  [write-byte, get-addr]: New procedures.
  Adjust to write to PORT.
  (compile-bytecode): Update accordingly.

* test-suite/tests/asm-to-bytecode.test (munge-bytecode): Return a
  bytevector instead of a u8vector.
  (comp-test): Deal with bytevectors.
module/language/assembly/compile-bytecode.scm
test-suite/tests/asm-to-bytecode.test