Opened 10 years ago

Last modified 18 months ago

#373 new defect

Two-way-streams and gray streams

Reported by: Helmut Eller Owned by:
Priority: major Milestone: 1.9.3
Component: streams Version: 1.4.0-dev
Keywords: Cc:
Parent Tickets:

Description

ABCL runs into troubles with the following example:

shell> cat test.lisp
(in-package cl-user)

(require 'gray-streams)

(defclass out (gray-streams:fundamental-character-output-stream)
  ((buffer :initform (make-array 200 :element-type 'character
				 :adjustable t :fill-pointer 0)
	   :reader out-buffer)))

(defmethod gray-streams:stream-write-char ((s out) (c character))
  (vector-push-extend c (out-buffer s)))

(let ((out (make-instance 'out)))
  (write-string "foo" (make-two-way-stream *standard-input* out))
  (assert (equal "foo" (out-buffer out))))

shell> abcl
Armed Bear Common Lisp 1.4.0-dev-svn-14730
Java 1.7.0_03 Oracle Corporation
OpenJDK Client VM
Low-level initialization completed in 0.841 seconds.
Startup completed in 4.419 seconds.
Loading /home/helmut/.abclrc completed in 0.108 seconds.
Type ":help" for a list of available commands.
CL-USER(1): (load "test.lisp")
Error loading /raid/home/helmut/lisp/test.lisp at line 16 (offset 488)
#<THREAD "interpreter" {8A408D}>: Debugger invoked on condition of type TYPE-ERROR
  The value #<OUT {940A15}> is not of type STREAM.
Restarts:
  0: TOP-LEVEL Return to top level.
[1] CL-USER(2):

The expected outcome is that assertion the succeeds.

Change History (14)

comment:1 Changed 10 years ago by Mark Evenson

Milestone: 1.4.0
Version: 1.4.0-dev

comment:2 Changed 8 years ago by Mark Evenson

Milestone: 1.4.01.5.0

Ticket retargeted after milestone closed

comment:3 Changed 8 years ago by Mark Evenson

Milestone: 1.5.01.6.0

Ticket retargeted after milestone closed

comment:4 Changed 5 years ago by Mark Evenson

Milestone: 1.6.01.6.1

Ticket retargeted after milestone closed

comment:5 Changed 5 years ago by Mark Evenson

Milestone: 1.6.11.6.2

Ticket retargeted after milestone closed

comment:6 Changed 5 years ago by Mark Evenson

Milestone: 1.6.21.7.0

comment:7 Changed 5 years ago by Mark Evenson

Milestone: 1.7.01.7.1

Ticket retargeted after milestone closed

comment:8 Changed 4 years ago by Mark Evenson

Milestone: 1.7.11.7.2

Ticket retargeted after milestone closed

comment:9 Changed 4 years ago by Mark Evenson

Milestone: 1.7.21.8.0

Milestone renamed

comment:10 Changed 4 years ago by Mark Evenson

Milestone: 1.8.01.8.1

Ticket retargeted after milestone closed

comment:11 Changed 3 years ago by Mark Evenson

Milestone: 1.8.11.9.0

comment:12 Changed 23 months ago by Mark Evenson

Milestone: 1.9.01.9.1

comment:13 Changed 22 months ago by Mark Evenson

Milestone: 1.9.11.9.2

comment:14 Changed 18 months ago by Mark Evenson

Milestone: 1.9.21.9.3
Note: See TracTickets for help on using tickets.