crytic / crytic/slither

[Bug]: incorrect cfg when more than one arguments of a function call are ternary expressions

Open
#1,851 3 comments 0 reactions 0 assignees View on GitHub
bug cfg
Dominant language
Python
Stars
6.4k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

### Describe the issue:

When more than one arguments of a function call are ternary expressions, only one of the ternary expression are included in CFG.

### Code example to reproduce the issue:

```solidity
contract A {
function f(uint x) public {
g(x > 0 ? 1 : 2, x > 1 ? 3 : 4);
}
function g(uint x, uint y) private {
}
}
```

### Version:

0.9.3

### Relevant log output:

```shell
See the CFG below.
```

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.