• 0 Posts
  • 9 Comments
Joined 4 months ago
cake
Cake day: January 25th, 2026

help-circle


  • What do you mean by “abstract away”, and what about it is exclusive to headers?

    Eg most languages have something like a trait or interface wherein you can put a list of definitions (optionally with a default aka “inline” implementation) which are then actually implemented elsewhere. This is considered useful by everyone because it allows multiple implementations to be associated with 1 name. They are generally not desired in cases where only 1 implementation will ever be written.

    AFAIK the only use case where headers accomplish the same is if they’re treated as documentation for an API that could be implemented by any library.

    Admittedly certain programming styles benefit immensely from headers, despite the drawbacks to “design as you go” programming.