Skip to content
Tcl Source Code View Ticket
Login

View Ticket

clock scan - discrepancy with documentation

Closed / Accepted1573884fffffffffffffffffffffffffffffffffCreated 20 years agoUpdated 20 years ago
Descriptionplain2006-10-09 17:12:55
The manual for [clock] says....

%P
    On output, produces an indicator for the part of the day, A.M. 
    or P.M., appropriate to the given locale. If the script of the 
    given locale supports multiple letterforms, lowercase is 
    preferred. On input, matches the representation A.M. or P.M. 
    in the given locale, in either case.

Note: "A.M. or P.M."

In tclsh...

% clock scan "10 30 p.m." -format "%H %m %P"     
input string does not match supplied format
% clock scan "10 30 pm" -format "%H %m %P"
1160402400

I would request that %p and %P be able to parse :
"PM", "P.M", "P.M.", "pm", "p.m", and "p.m."

Or change the manual to reflect the actual behavior.
kennykbplain2007-04-20 06:37:39
Logged In: YES 
user_id=99768
Originator: NO

Fixed the manual.
Log in (anonymous is fine) to add a comment.