google / google/CodeCity

Date conversion error: '' + new Date() returns numeric string, not human-readable form

Open
#380 5 comments 0 reactions 0 assignees View on GitHub
bug server
Dominant language
JavaScript
Stars
198
Forks
38
PR merge metrics
No merged PRs in 30d

Description

For some reason `'' + new Date()` evaluates to a string of digits (e.g., ` // Schedule ourselves to be run again at time.
"`) instead of a formatted date (e.g. `"Sat Jun 06 2020 17:00:00 GMT+0000 (Coordinated Universal Time)"`).

Presumably an issue with the internal `Interpreter.prototype.Date.prototype.toString` method, since the built-in `String` method is not invoked for automatic conversions by `+`.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.