Ticket #888 (closed defect: invalid)

Opened 20 months ago

Last modified 20 months ago

format can produce 0+3

Reported by: Arthur Owned by:
Priority: normal Milestone:
Component: ANSI CL Compliance Version: trunk
Keywords: Cc:

Description

In latest trunk, and afaik all earlier versions too, (format nil "~3,'0@D" 3) produces "0+3" - not "+03" as I'd expect.

Change History

Changed 20 months ago by gb

  • status changed from new to closed
  • resolution set to invalid

22.3.2.2 (the description of ~D) says that "spaces are inserted on the left ..." and that if a pad character is provided it's used instead of #\space.

The output "0+3" certainly looks weird (if one is used to thinking of using #\0 as a pad character to produce leading zeroes), but the pad character just something that's "inserted on the left" if the digits and sign require fewer than mincol characters.

Changed 20 months ago by gb

Uh, "the pad character IS just something ..."

Note: See TracTickets for help on using tickets.