23 lines
304 B
C++
23 lines
304 B
C++
#include <iostream>
|
|
|
|
#ifdef _WIN32
|
|
#define EXPORT __declspec(dllexport)
|
|
#else
|
|
#define EXPORT
|
|
#endif
|
|
|
|
using namespace std;
|
|
|
|
class nt {
|
|
public:
|
|
void print() {
|
|
cout << "Hello from object\n";
|
|
}
|
|
};
|
|
|
|
EXPORT void print_obj() {
|
|
cout << "Hello from function\n";
|
|
nt obj;
|
|
obj.print();
|
|
}
|