Skip to content

Lost in include dependency loop #348

@laanwj

Description

@laanwj

So I thought I'd spend my sunday afternoon porting my GUI to the newest bitcoin git version. I got lost in the forest on the first file I tried to compile, though;

qt/bitcoin.cpp (mine) includes util.h
util.h includes uint256.h
uint256.h includes serialize.h
serialize.h includes wallet.h
wallet.h includes bignum.h
bignum.h includes utl.h

That's one epic dependency loop. I see no trivial way to split it up (like adding forward declaration), as there is a lot of inline code in the headers that uses the actual types.

Of course, I could get my hacksaw and saw off pieces here and there until this until it compiles again. But it might be better to make an actual plan as to how to split up the includes. How is this supposed to work?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions