Commit 93cbb579 authored by Frank Tang's avatar Frank Tang Committed by Commit Bot

[Intl] Remove incorrect CHECK

The CHECK was introduced in d7ae63e6.

The first time the property got read by ToDateTimeOptions
and the test will cause the needsDefault in ToDateTimeOptions
be false. Then in step 22 of InitializeDateTimeFormat,
it will get all undefined and cause the
skeleton to be empty string. If we only pass in empty options, the
defaults will be filled by ToDateTimeOptions and won't cause any
CHECK failure.


Bug: chromium:888299
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I3ee14434f0708eaaea78cc8857591152d1bdef8a
Reviewed-on: https://chromium-review.googlesource.com/1241316
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: 's avatarSathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56226}
parent e3eedfb4
......@@ -836,7 +836,6 @@ MaybeHandle<JSDateTimeFormat> JSDateTimeFormat::Initialize(
Maybe<std::string> maybe_skeleton =
JSDateTimeFormat::OptionsToSkeleton(isolate, options);
MAYBE_RETURN(maybe_skeleton, Handle<JSDateTimeFormat>());
CHECK(!maybe_skeleton.FromJust().empty());
std::string skeleton = maybe_skeleton.FromJust();
// 13. Set dateTimeFormat.[[Calendar]] to r.[[ca]].
......
// Copyright 2016 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
var i = 0;
new Intl.DateTimeFormat(
undefined, { get hour() { if (i == 0) { i = 1; return 'numeric'} } });
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment