-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Description
Hallo! I'm trying to parse times in RFC-822 format like Thu, 16 Jun 2016 04:16:41 +0000. As best as I can tell, the parse syntax in times can't handle the UTC offset not containing a colon:
var parsed = parse("Thu, 16 Jun 2016 04:16:41 -1100", "ddd, dd MMM yyyy hh:mm:ss zzzz")
echo format(parsed, "ZZZ") # prints "PDT", my local timezone
var parsed = parse("Thu, 16 Jun 2016 04:16:41 -0000", "ddd, dd MMM yyyy hh:mm:ss zzzz")
echo format(parsed, "ZZZ") # prints "PDT" again
var parsed = parse("Thu, 16 Jun 2016 04:16:41 +0700", "ddd, dd MMM yyyy hh:mm:ss zzzz")
echo format(parsed, "ZZZ") # still PDT
(The rest of the string is parsed correctly.)
Am I missing something? Derping? Found a bug?