ww: implement package initialization
This commit is contained in:
@@ -75,7 +75,7 @@ export type stream = struct {
|
||||
//
|
||||
// Returns the stream BY VALUE; the caller passes `&b.vt` to the io
|
||||
// dispatchers. Mirrors ref/hare/bufio/stream.ha:69.
|
||||
export fn init(src: io.stream, rbuf: []u8, wbuf: []u8) stream = {
|
||||
export fn newstream(src: io.stream, rbuf: []u8, wbuf: []u8) stream = {
|
||||
let r: stream;
|
||||
r.vt.reader = (&bread): *io.reader;
|
||||
r.vt.writer = (&bwrite): *io.writer;
|
||||
|
||||
Reference in New Issue
Block a user