|
|
|
|
|
by ryl00
2774 days ago
|
|
> I want it all, I want to have my cake and eat it too. Conceptually this should be possible with some preprocessor/header tinkering; something like: private.h: struct Bar {
double x;
double y;
};
#define BAR_DEFINED
public.h: #ifndef BAR_DEFINED
struct Bar {
char opaque[16];
};
#endif
struct Foo {
Bar bar;
};
consumer.cpp: #include "public.h"
private_implementation.cpp: #include "private.h"
#include "public.h"
|
|