| Index: src/objects.cc
|
| diff --git a/src/objects.cc b/src/objects.cc
|
| index 946388e274c3a5a312bf7f5f21497a90482447ae..f2f58cbe7faf4680da80d344600b0c58d45757ac 100644
|
| --- a/src/objects.cc
|
| +++ b/src/objects.cc
|
| @@ -12696,7 +12696,8 @@ void JSFunction::SetInstancePrototype(Handle<JSFunction> function,
|
|
|
| void JSFunction::SetPrototype(Handle<JSFunction> function,
|
| Handle<Object> value) {
|
| - DCHECK(function->IsConstructor());
|
| + DCHECK(function->IsConstructor() ||
|
| + IsGeneratorFunction(function->shared()->kind()));
|
| Handle<Object> construct_prototype = value;
|
|
|
| // If the value is not a JSReceiver, store the value in the map's
|
|
|