Skip to content

Instantly share code, notes, and snippets.

@vinzenz
Created October 8, 2009 22:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vinzenz/205491 to your computer and use it in GitHub Desktop.
Save vinzenz/205491 to your computer and use it in GitHub Desktop.
#include "pimpl.h"
struct test::inner{ int x; inner() : x(42) {} };
test::test():pimpl(new inner()){}
test::~test(){}
#include <boost/shared_ptr.hpp>
struct test{
test();
~test();
struct inner;
boost::shared_ptr<inner> pimpl;
};
#include "pimpl.h"
int main(){
test t;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment