Static Analyzer for Solidity
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
slither/tests/unit/slithir/test_data/assembly_storage_slot.sol

18 lines
526 B

contract YYY {
mapping(address => uint256) private _counters;
function _getPackedBucketGlobalState(uint256 bucketId) internal view returns (uint256 packedGlobalState) {
assembly {
mstore(0x0, bucketId)
mstore(0x20, _counters.slot)
let slot := keccak256(0x0, 0x40)
packedGlobalState := sload(slot)
}
}
}
contract XXX is YYY {
function getPackedBucketGlobalState(uint256 bucketId) external {
_getPackedBucketGlobalState(bucketId);
}
}