Skip to content

Instantly share code, notes, and snippets.

@aristidb
Created December 4, 2008 18:58
Show Gist options
  • Save aristidb/32023 to your computer and use it in GitHub Desktop.
Save aristidb/32023 to your computer and use it in GitHub Desktop.
template<size_t (curl::*Method)(void *, size_t, size_t, void *)>
static size_t curl::c_handle_curl(void *ptr, size_t size, size_t nmemb, void *stream) {
curl *self = static_cast<curl*>(ptr);
return (self->*Method)(ptr, size, nmemb, stream);
}
foo ( &curl::c_handle_curl<&curl::method_name> );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment