aboutsummaryrefslogtreecommitdiff
path: root/module/datetime.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-02-13 22:12:07 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2022-02-13 22:12:07 +0100
commit229600842bdeac14f0a85bd17f8e6af222113482 (patch)
tree1cf08341671e5d9dc63b0b26336e33b7b0bdc250 /module/datetime.scm
parentDatetime rewrote parse-month. (diff)
downloadcalp-229600842bdeac14f0a85bd17f8e6af222113482.tar.gz
calp-229600842bdeac14f0a85bd17f8e6af222113482.tar.xz
Datetime remove old commented parse-month.
Diffstat (limited to 'module/datetime.scm')
-rw-r--r--module/datetime.scm19
1 files changed, 0 insertions, 19 deletions
diff --git a/module/datetime.scm b/module/datetime.scm
index d0025316..95f2f77d 100644
--- a/module/datetime.scm
+++ b/module/datetime.scm
@@ -642,25 +642,6 @@
;;; Input
-#;
-(define (parse-month str)
- "Get month number from a (shortened) monthname.
-Returns -1 on failure"
- (let loop ((i 1)
- (months (map (compose string-locale-downcase locale-month)
- (iota 12 1))))
- (if (null? months)
- -1
- (let ((len (min (string-length (car months))
- (string-length str))))
- (if (string=?
- (string-take (string-downcase str) len)
- (string-take (car months) len))
- i
- (loop (1+ i) (cdr months)))))))
-
-
-
(define*-public (parse-month str optional: (locale %global-locale))
"Get month number from a (shortened) monthname.
Returns -1 on failure"