You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
echo"pragma solidity ^0.5.3;contract C { struct S { uint x; } function x() external pure returns (address) { S memory s; s.x = 1; }}"> a.sol && slither a.sol
INFO:Detectors:
s inC.x() (a.sol#7) is a local variable never initialiazed
Reference: https://github.com/crytic/slither/wiki/Detector-Documentation#uninitialized-local-variables
INFO:Slither:a.sol analyzed (1 contracts with 38 detectors), 1 result(s) found
Returns that s is never initialized, when in fact we populate all of its fields in the following line
Related to #270 and #112 probably
The text was updated successfully, but these errors were encountered:
I think it is related to the current limitation of our IR, and the way it handles structure/mapping. It should be fixed once our IR refactoring is done (#346)
0xalpharush
changed the title
False positive on uninitialized local variable
Tracking: imprecision of data dependencies on structures and arrays
Feb 1, 2023
Returns that
s
is never initialized, when in fact we populate all of its fields in the following lineRelated to #270 and #112 probably
The text was updated successfully, but these errors were encountered: