Skip to content

Forge Flatten creates duplicate declarations (unable to compile) #6022

@daweth

Description

@daweth

Component

Forge

Have you ensured that all of these are up to date?

  • Foundry
  • Foundryup

What version of Foundry are you on?

forge 0.2.0 (95a93cd 2023-08-25T00:32:44.694202000Z)

What command(s) is the bug in?

forge flatten

Operating System

macOS (Apple Silicon)

Describe the bug

To repro:

https://github.com/balancer/balancer-v2-monorepo/blob/master/pkg/vault/contracts/Vault.sol
Clone the repo and call forge flatten Vault.sol > VaultFlattened.sol

Try to compile VaultFlattened.sol in a blank forge repo

Screen Shot 2023-10-10 at 5 22 40 PM

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions