Skip to content

Instantly share code, notes, and snippets.

@xadh00m
Created June 30, 2012 14:04
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 xadh00m/3023874 to your computer and use it in GitHub Desktop.
Save xadh00m/3023874 to your computer and use it in GitHub Desktop.
// create the dependency list
DependencyList dependencyList;
// (...gather all required dependencies and add them to the list...)
// create the plugin instance
Plugin* plugin = createPlugin();
// create a shared pointer managing the lifetime of the plugin and its dependencies
PluginPtr pluginPtr(plugin, DependencyDeleter<plugin>(dependencyList));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment