96cad7de9c
* tests: reorganize testing packages * gitignore and minor changes
28 lines
687 B
Solidity
28 lines
687 B
Solidity
pragma solidity ^0.5.17;
|
|
|
|
import "../lib/os/DelegateProxy.sol";
|
|
import "../lib/os/UnstructuredStorage.sol";
|
|
|
|
|
|
contract ThinProxy is DelegateProxy {
|
|
using UnstructuredStorage for bytes32;
|
|
|
|
constructor(address _implementation) public {
|
|
_implementationSlot().setStorageAddress(_implementation);
|
|
}
|
|
|
|
function () external {
|
|
delegatedFwd(implementation(), msg.data);
|
|
}
|
|
|
|
function proxyType() public pure returns (uint256) {
|
|
return FORWARDING;
|
|
}
|
|
|
|
function implementation() public view returns (address) {
|
|
return _implementationSlot().getStorageAddress();
|
|
}
|
|
|
|
function _implementationSlot() internal pure returns (bytes32);
|
|
}
|