chakra-core / chakra-core/ChakraCore

ASSERTION Failure: "reg < this->GetConstantCount()" in ChakraCore/lib/Runtime/./Base/FunctionBody.h, line 2977

Open
#6,793 1 comment 0 reactions 0 assignees View on GitHub
Needs Triage
Dominant language
JavaScript
Stars
9.3k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

### commit
41ad58a9eebf8d52a83424c8fccfaacdb14105ec

### Build platform
Ubuntu 20.04

### Build steps

```
./build.sh --debug
```

### poc

```js
function foo() {
(function () {
function bar(
a = 1,
b = function () {
return a;
}
)
{
var arguments = 3;
}
}());
}

WScript.Attach(foo);
```

### assert log

```
ASSERTION 2397793: (ChakraCore/lib/Runtime/./Base/FunctionBody.h, line 2977) reg < this->GetConstantCount()
Failure: (reg < this->GetConstantCount())
Illegal instruction
```

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.