Opened 3 years ago

#1399 new defect

potential FORMAT conformity issue

Reported by: attila.lendvai Owned by:
Priority: normal Milestone:
Component: ANSI CL Compliance Version: trunk
Keywords: format Cc:

Description

(format t "~@< printed as one block even if errors happen while printing ~:@>")

it works fine on SBCL, CLASP, ECL, but demands an argument on ccl.

i don't know what is the valid behavior, and it's not an issue for me anymore, so feel free to close/ignore this.

all i know is what others told me:

#lisp irc on 2016-12-29:

(01:52:04) pjb: (format t "~@<Roger, go on testing...~@:>" #+ccl nil) ; I think it's a conformity bug in ccl.
(01:53:51) pjb: On the other hand, I don't see that  ~@:>  is any different than ~>.
(01:59:58) pjb: Ah, there's 22.3.5.2.
(02:00:10) pjb: So with ~:> it's a logical block, without it's a justification.
(02:01:27) pjb: and with ~@:> it's a fill-style conditional newlines after each block.
(02:02:25) pjb: So when you use ~:> or ~@:>, you seem to need an argument, so ccl is correct here, and sbcl and clasp implement an extension, in accepting it without a required argument.
(02:02:49) pjb: (format t "~@<Roger, go on testing...~>") works nicely in ccl.
(02:04:23) pjb: I just learned that there are two different meanings for ~< depending on ~:> or ~> !
(02:04:32) pjb: If you think I know anything about ~<…
(02:07:53) pjb: attila_lendvai: but if you try:    clall '(format t "~@%~<Roger, go on testing. On the twelfth day of Christmas my true love gave to me twelve drummers drumming, eleven pipers piping, ten lords a-leaping, nine ladies dancing, eight maids a-milking, seven swans a-swimming, six geese a-laying, five golden rings, four calling birds, three French hens, two turtle doves and a partridge in a pear tree.~:@>")'
(02:08:30) pjb: s/~@%~</~%~@</   and then s/~@</~</
(02:08:49) pjb: you will see that even implementers don't understand it very well, given the differences of results…
(02:10:42) pjb: Eg. ~<…~:@>  justifies the text only with ecl and sbcl, not with the others (but they all need NIL but sbcl or ecl).

Change History (0)

Note: See TracTickets for help on using tickets.