Closed
Bug 459440
Opened 17 years ago
Closed 16 years ago
TM: jit calls to remaining Date constructors
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 487134
People
(Reporter: duncan.loveday, Unassigned)
References
Details
(Keywords: testcase)
Attachments
(1 file)
3.27 KB,
text/html
|
Details |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b2pre) Gecko/20081009 Minefield/3.1b2pre
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b2pre) Gecko/20081009 Minefield/3.1b2pre
Work out a good way to allow all Date constructors to be handled by tracemonkey, as discussed by BZ's in bug 456165 comment #25
Reproducible: Always
Steps to Reproduce:
1.
2.
3.
Reporter | ||
Comment 1•17 years ago
|
||
This is a page that lets you run whatever constructors you want, as many times as you want - might be useful or might not.
Reporter | ||
Comment 2•17 years ago
|
||
Boris, according to the docs at http://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Date it's only the last four numerics that are optional but there are also constructors from a formatted date string and from a single numeric timestamp so still quite a few.
Keywords: testcase
![]() |
||
Comment 3•17 years ago
|
||
Right. So the last 4 args are optional no matter what, but if you leave off the last 5 args then the remaining one is treated as a timestamp or string... no matter how you slice it, that means seven different constructors.
I talked to gal about this a little bit today, and we might just do this by boxing the args.
![]() |
||
Updated•17 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Reporter | ||
Comment 4•17 years ago
|
||
Just a silly thought: You couldn't do a transformation along the lines of
d=new Date(a,b,c) => { d=new Date(); d.setA(s); d.setB(b); d.setC(c); }
taking advantage of the fact that Date happens to provide setter methods for all the constructor args ?
![]() |
||
Comment 5•17 years ago
|
||
Not easily, especially for |new Data(a)|. Note that we don't trace any of those setter methods yet either.
Updated•16 years ago
|
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•