diff options
author | Linus Groh <mail@linusgroh.de> | 2022-05-06 20:45:25 +0200 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2022-05-06 22:32:47 +0200 |
commit | f7c9bd0760d21e1c32d59cb62fe36728736b47bd (patch) | |
tree | 6efb90cf7551e6b22970c86effef9ed8bbe65325 /Userland/Libraries/LibJS/Runtime/Date.h | |
parent | b9b3d01bea2b8e5455f17eedf1acd6ac9ffe31ec (diff) | |
download | serenity-f7c9bd0760d21e1c32d59cb62fe36728736b47bd.zip |
LibJS: Convert remaining Date AOs using JS::Value as in/output to double
There was an awful lot of JS::Value <-> double conversion going on, even
through these AOs only work with number values anyway.
They don't need a global object either as they won't allocate or throw,
that was simply to pass it to infallible calls of ToIntegerOrInfinity.
Diffstat (limited to 'Userland/Libraries/LibJS/Runtime/Date.h')
-rw-r--r-- | Userland/Libraries/LibJS/Runtime/Date.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Userland/Libraries/LibJS/Runtime/Date.h b/Userland/Libraries/LibJS/Runtime/Date.h index 25748c9030..6bcbf2d792 100644 --- a/Userland/Libraries/LibJS/Runtime/Date.h +++ b/Userland/Libraries/LibJS/Runtime/Date.h @@ -63,9 +63,9 @@ double local_time(double time); double utc_time(double time); double day(double); double time_within_day(double); -Value make_time(GlobalObject& global_object, Value hour, Value min, Value sec, Value ms); -Value make_day(GlobalObject& global_object, Value year, Value month, Value date); -Value make_date(Value day, Value time); -Value time_clip(GlobalObject& global_object, Value time); +double make_time(double hour, double min, double sec, double ms); +double make_day(double year, double month, double date); +double make_date(double day, double time); +double time_clip(double time); } |