1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:58:11 +00:00

LibJS: Implement Infinity

This commit is contained in:
Linus Groh 2020-04-02 16:59:01 +01:00 committed by Andreas Kling
parent 40b3203941
commit 543c6e00db
5 changed files with 40 additions and 0 deletions

View file

@ -18,7 +18,10 @@ GlobalObject::GlobalObject()
put_native_function("gc", gc);
put_native_function("isNaN", is_nan);
// FIXME: These are read-only in ES5
put("NaN", js_nan());
put("Infinity", js_infinity());
put("console", heap().allocate<ConsoleObject>());
put("Date", heap().allocate<DateConstructor>());
put("Error", heap().allocate<ErrorConstructor>());