crytic / crytic/slither

UnaryOperation/BinaryOperation do not have type information as expected

Open
#1,701 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Python
Stars
6.4k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

### Describe the desired feature

UnaryOperation/BinaryOperation are subclasses of ExpressionTyped class, however their "type" property records their "operation type" (such as `BANG`, `TILD`, `DELETE`), not Solidity types (like `int` or `uint`). I think this is counter-intuitive and certainly not consistent with other subclasses of ExpressionTyped like `AssignmentOperation`, `Identifier`, etc.

Unary/Binary operation classes should record `expression["typeDescriptions"]["typeString"]` in the `type` property and have a separate property (say, "operation") for the type of operation.

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.