Skip to content

Instantly share code, notes, and snippets.

@hpcx82
Created July 13, 2011 12:44
Show Gist options
  • Save hpcx82/1080228 to your computer and use it in GitHub Desktop.
Save hpcx82/1080228 to your computer and use it in GitHub Desktop.
#pragma once
template <class T>
class Queue
{
public:
static int Size;
};
#ifdef TEMPLATE_EXPORTS
# define DECLSPECIFIER __declspec(dllexport)
# define EXPIMP_TEMPLATE
#else
# define DECLSPECIFIER __declspec(dllimport)
# define EXPIMP_TEMPLATE
#endif
template <class T> int Queue<T>::Size = 0;
EXPIMP_TEMPLATE template class DECLSPECIFIER Queue<int>;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment