Akagi201 / solc-align

A tool to align solidity contract storage and calldata struct to 256 bits to maximazing storage reduction.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

solc-align

A tool to align solidity contract storage and calldata struct to 256 bits to maximizing storage reduction.

Features

  • Align to 32 bytes(256 bits) for calldata struct.
  • Use stable sort to make the same size bytes type in the same order as input.
  • Align contract storage, which needs AST parser.

Install

cargo install --git https://github.com/Akagi201/solc-align.git

Usage

read input.txt for example.

case 1:

just print to stdout.

solc-align ./input.txt

case 2:

write result to a file.

solc-align ./input.txt ./output.txt

About

A tool to align solidity contract storage and calldata struct to 256 bits to maximazing storage reduction.

License:Apache License 2.0


Languages

Language:Rust 100.0%