This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
Having MediaKeySession.expiration return a Date is a bad idea. There's a big thread at https://www.w3.org/Bugs/Public/show_bug.cgi?id=22824 about why Date is bad, but the short of it is that if you have a Date-valued attribute it will return a new Date object every single time you do the get. This means that you get things like: if (foo.expired == foo.expired) // Always tests false! So how about making the expiration the number of milliseconds since the Unix epoch after which the license expires? This can then be passed into a JavaScript Date() constructor if desired. NaN can be returned when the expiration is not known.
Are you proposing to use UnrestrictedDouble? UnsignedLongLong would also work (the Date() constructor takes an integer) but would not support NaN.
"unrestricted double" would work here, yes.
https://dvcs.w3.org/hg/html-media/rev/78799a7b0a9d