Skip to content

Fix multiple definition errors by gating implementation behind THIRTEEN_IMPLEMENTATION#20

Merged
Atrix256 merged 1 commit intoAtrix256:mainfrom
D13David:main
Mar 18, 2026
Merged

Fix multiple definition errors by gating implementation behind THIRTEEN_IMPLEMENTATION#20
Atrix256 merged 1 commit intoAtrix256:mainfrom
D13David:main

Conversation

@D13David
Copy link
Contributor

Currently thirteen.h contains both declarations and implementations unconditionally. When the header is included in multiple translation units, this can lead to multiple definition linker errors.

Usage: define THIRTEEN_IMPLEMENTATION in exactly one .c/.cpp file before including thirteen.h; include the header normally everywhere else.

…EN_IMPLEMENTATION.

Currently thirteen.h contains both declarations and implementations unconditionally.
When the header is included in multiple translation units, this can lead to multiple definition linker errors.

Usage: define THIRTEEN_IMPLEMENTATION in exactly one .c/.cpp file before including thirteen.h; include the header normally everywhere else.
@Atrix256
Copy link
Owner

That was very kind of you to make this change. I'll get this merged and update the instruction docs tonight.

@Atrix256 Atrix256 merged commit b809633 into Atrix256:main Mar 18, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants