foundry-rs / compilers

Utilities for working with native solc and compiling projects.
Apache License 2.0
58 stars 36 forks source link

feat: use cached artifacts if solc config is almost the same #87

Closed klkvr closed 4 months ago

klkvr commented 4 months ago

If the only difference between cached vs current solc config is outputSelection which is a subset of the cached output selection, then it's safe to use cached artifact.

I am currently adding logic to foundry to request only abi output and it would be nice if we could use cached abi where possible.

Impl is pretty ugly, but not sure how to make it better without cloning