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/ast-parsing/functioncall-0.8.0.sol

56 lines
1.0 KiB

contract I {
constructor() public payable {}
}
contract C {
struct S {
uint a;
uint b;
}
struct T {
S s1;
S s2;
}
function f() public payable {
publicTarget();
this.publicTarget();
this.publicTarget{value: 1 ether}();
this.publicTarget{value: 1 ether};
this.publicTarget{gas: 10000}();
this.publicTarget{gas: 20000, value: 2 ether}();
internalTarget(1, 2);
S({a: 5, b: 6});
T({s1: S({a: 1, b: 2}), s2: S({a: 3, b: 4})});
function(uint) external payable ptr;
ptr{value: 10 ether}(1);
I(msg.sender);
new I();
(new I){value: 1 ether}();
(new I){value: 1 ether, salt: hex"0a"}();
type(I);
type(int);
abi.encode(1, 2, 3);
abi.decode(msg.data, (uint, uint[], I));
payable(address(1));
}
function publicTarget() public payable {
}
function internalTarget(uint a, uint b) public {
}
}