Skip to content

Instantly share code, notes, and snippets.

@sayurin
Created October 17, 2014 04:02
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 sayurin/7a14636a74c5bbf8b8d5 to your computer and use it in GitHub Desktop.
Save sayurin/7a14636a74c5bbf8b8d5 to your computer and use it in GitHub Desktop.
#include <type_traits>
template<typename Interface>
struct vtable{
typedef typename std::remove_pointer_t<decltype(Interface::lpVtbl)> type;
};
template<typename Interface>
using vtable_t = typename Vtable<Interface>::type;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment