Yoba Perl
common.hpp
1 #ifndef YOBAPERL_COMMON_HPP
2 #define YOBAPERL_COMMON_HPP
3 
4 
5 // STL
6 #include <iostream>
7 #include <string>
8 #include <sstream>
9 #include <vector>
10 #include <list>
11 #include <unordered_map>
12 #include <algorithm>
13 #include <functional>
14 #include <memory>
15 
16 
17 // Defines
18 #define my_perl _interpreter
19 
20 #ifndef YOBAPERL_MULTIPLICITY
21  #define PERL_NO_GET_CONTEXT
22 #endif
23 
24 #ifdef DEBUGGING
25  #undef NDEBUG
26  #include <cassert>
27 #endif
28 
29 #define YOBAPERL_UNUSED(x) PERL_UNUSED_ARG(x)
30 #define YOBAPERL_ASSERT(x) assert(x)
31 
32 #if __GNUC__ >= 4
33  #define YOBAPERL_EXPORT __attribute__ ((__visibility__ ("default")))
34 #elif defined(_WIN32)
35  #define YOBAPERL_EXPORT __declspec(dllexport)
36 #else
37  #define YOBAPERL_EXPORT
38 #endif
39 
40 
41 // Perl headers
42 namespace yoba { extern "C" {
43 
44 #include <EXTERN.h>
45 #include <perl.h>
46 
47 void xs_init(pTHX);
48 
49 }}
50 
51 #endif // YOBAPERL_COMMON_HPP
Definition: array.cpp:5