Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support more date formats supported by V8 #224

Open
gbrail opened this issue Aug 5, 2015 · 2 comments
Open

Support more date formats supported by V8 #224

gbrail opened this issue Aug 5, 2015 · 2 comments
Labels
feature Issues considered a new feature

Comments

@gbrail
Copy link
Collaborator

gbrail commented Aug 5, 2015

A Trireme user found the following Date format that works in V8, but not in Rhino:

$ node

new Date('March 31, 2013 23:59:59.9999')
Sun Mar 31 2013 23:59:59 GMT-0700 (PDT)

$ rhino
Rhino 1.7.6 2015 04 15
js> new Date('March 31, 2013 23:59:59.9999')
Invalid Date

In the interests of V8 compatibility, we should try to figure out what Date format parsing rules they use and implement them.

apigee/trireme#123

@p-bakker
Copy link
Collaborator

p-bakker commented Jul 5, 2021

As Date string parsing through the Date constructor (or Date.parse) is discouraged and the format that V8 seems to parse is not the format that must be parsable according to the EcmaSript spec, if we'd implement this, I think it should be behind the Context.FEATURE_V8_EXTENSIONS flag

@p-bakker p-bakker added the feature Issues considered a new feature label Jul 5, 2021
@p-bakker
Copy link
Collaborator

Probably better to focus on implementing Temporal support in Rhino, instead of trying to implement the same, non-standard behaviour as V8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Issues considered a new feature
Projects
None yet
Development

No branches or pull requests

2 participants