forked from facebook/hermes
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Summary: Convert `Date()` and `new Date()` to HostFunctions. This was a little trickier to pull off. The main reason is because they both return object/string ids which are not defined if you just return the value coming from `runtime_`. So the solution is to recreate the object/string in the tracing runtime with the value from the untraced `runtime_` once you run the nondeterministic function. Reviewed By: kodafb Differential Revision: D37229133 fbshipit-source-id: 0022e8c2b49d77c1ef5717b1e5026281d9a94bee
- Loading branch information
1 parent
068d4ab
commit 945b8c3
Showing
3 changed files
with
132 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters