Go to the documentation of this file.
27 #ifndef SOL_SINGLE_INCLUDE_FORWARD_HPP
28 #define SOL_SINGLE_INCLUDE_FORWARD_HPP
32 #ifndef SOL_FORWARD_HPP
33 #define SOL_FORWARD_HPP
39 #define SOL_VERSION_MAJOR 3
40 #define SOL_VERSION_MINOR 2
41 #define SOL_VERSION_PATCH 3
42 #define SOL_VERSION_STRING "3.2.3"
43 #define SOL_VERSION ((SOL_VERSION_MAJOR * 100000) + (SOL_VERSION_MINOR * 100) + (SOL_VERSION_PATCH))
45 #define SOL_TOKEN_TO_STRING_POST_EXPANSION_I_(_TOKEN) #_TOKEN
46 #define SOL_TOKEN_TO_STRING_I_(_TOKEN) SOL_TOKEN_TO_STRING_POST_EXPANSION_I_(_TOKEN)
48 #define SOL_CONCAT_TOKENS_POST_EXPANSION_I_(_LEFT, _RIGHT) _LEFT##_RIGHT
49 #define SOL_CONCAT_TOKENS_I_(_LEFT, _RIGHT) SOL_CONCAT_TOKENS_POST_EXPANSION_I_(_LEFT, _RIGHT)
51 #define SOL_RAW_IS_ON(OP_SYMBOL) ((3 OP_SYMBOL 3) != 0)
52 #define SOL_RAW_IS_OFF(OP_SYMBOL) ((3 OP_SYMBOL 3) == 0)
53 #define SOL_RAW_IS_DEFAULT_ON(OP_SYMBOL) ((3 OP_SYMBOL 3) > 3)
54 #define SOL_RAW_IS_DEFAULT_OFF(OP_SYMBOL) ((3 OP_SYMBOL 3 OP_SYMBOL 3) < 0)
56 #define SOL_IS_ON(OP_SYMBOL) SOL_RAW_IS_ON(OP_SYMBOL ## _I_)
57 #define SOL_IS_OFF(OP_SYMBOL) SOL_RAW_IS_OFF(OP_SYMBOL ## _I_)
58 #define SOL_IS_DEFAULT_ON(OP_SYMBOL) SOL_RAW_IS_DEFAULT_ON(OP_SYMBOL ## _I_)
59 #define SOL_IS_DEFAULT_OFF(OP_SYMBOL) SOL_RAW_IS_DEFAULT_OFF(OP_SYMBOL ## _I_)
63 #define SOL_DEFAULT_ON +
64 #define SOL_DEFAULT_OFF -
66 #if defined(SOL_BUILD_CXX_MODE)
67 #if (SOL_BUILD_CXX_MODE != 0)
68 #define SOL_BUILD_CXX_MODE_I_ SOL_ON
70 #define SOL_BUILD_CXX_MODE_I_ SOL_OFF
72 #elif defined(__cplusplus)
73 #define SOL_BUILD_CXX_MODE_I_ SOL_DEFAULT_ON
75 #define SOL_BUILD_CXX_MODE_I_ SOL_DEFAULT_OFF
78 #if defined(SOL_BUILD_C_MODE)
79 #if (SOL_BUILD_C_MODE != 0)
80 #define SOL_BUILD_C_MODE_I_ SOL_ON
82 #define SOL_BUILD_C_MODE_I_ SOL_OFF
84 #elif defined(__STDC__)
85 #define SOL_BUILD_C_MODE_I_ SOL_DEFAULT_ON
87 #define SOL_BUILD_C_MODE_I_ SOL_DEFAULT_OFF
90 #if SOL_IS_ON(SOL_BUILD_C_MODE)
100 #if defined(SOL_COMPILER_VCXX)
101 #if defined(SOL_COMPILER_VCXX != 0)
102 #define SOL_COMPILER_VCXX_I_ SOL_ON
104 #define SOL_COMPILER_VCXX_I_ SOL_OFF
106 #elif defined(_MSC_VER)
107 #define SOL_COMPILER_VCXX_I_ SOL_DEFAULT_ON
109 #define SOL_COMPILER_VCXX_I_ SOL_DEFAULT_OFF
112 #if defined(SOL_COMPILER_GCC)
113 #if defined(SOL_COMPILER_GCC != 0)
114 #define SOL_COMPILER_GCC_I_ SOL_ON
116 #define SOL_COMPILER_GCC_I_ SOL_OFF
118 #elif defined(__GNUC__)
119 #define SOL_COMPILER_GCC_I_ SOL_DEFAULT_ON
121 #define SOL_COMPILER_GCC_I_ SOL_DEFAULT_OFF
124 #if defined(SOL_COMPILER_CLANG)
125 #if defined(SOL_COMPILER_CLANG != 0)
126 #define SOL_COMPILER_CLANG_I_ SOL_ON
128 #define SOL_COMPILER_CLANG_I_ SOL_OFF
130 #elif defined(__clang__)
131 #define SOL_COMPILER_CLANG_I_ SOL_DEFAULT_ON
133 #define SOL_COMPILER_CLANG_I_ SOL_DEFAULT_OFF
136 #if defined(SOL_COMPILER_EDG)
137 #if defined(SOL_COMPILER_EDG != 0)
138 #define SOL_COMPILER_EDG_I_ SOL_ON
140 #define SOL_COMPILER_EDG_I_ SOL_OFF
143 #define SOL_COMPILER_EDG_I_ SOL_DEFAULT_OFF
146 #if defined(SOL_COMPILER_MINGW)
147 #if (SOL_COMPILER_MINGW != 0)
148 #define SOL_COMPILER_MINGW_I_ SOL_ON
150 #define SOL_COMPILER_MINGW_I_ SOL_OFF
152 #elif defined(__MINGW32__)
153 #define SOL_COMPILER_MINGW_I_ SOL_DEFAULT_ON
155 #define SOL_COMPILER_MINGW_I_ SOL_DEFAULT_OFF
158 #if SIZE_MAX <= 0xFFFFULL
159 #define SOL_PLATFORM_X16_I_ SOL_ON
160 #define SOL_PLATFORM_X86_I_ SOL_OFF
161 #define SOL_PLATFORM_X64_I_ SOL_OFF
162 #elif SIZE_MAX <= 0xFFFFFFFFULL
163 #define SOL_PLATFORM_X16_I_ SOL_OFF
164 #define SOL_PLATFORM_X86_I_ SOL_ON
165 #define SOL_PLATFORM_X64_I_ SOL_OFF
167 #define SOL_PLATFORM_X16_I_ SOL_OFF
168 #define SOL_PLATFORM_X86_I_ SOL_OFF
169 #define SOL_PLATFORM_X64_I_ SOL_ON
172 #define SOL_PLATFORM_ARM32_I_ SOL_OFF
173 #define SOL_PLATFORM_ARM64_I_ SOL_OFF
175 #if defined(SOL_PLATFORM_WINDOWS)
176 #if (SOL_PLATFORM_WINDOWS != 0)
177 #define SOL_PLATFORM_WINDOWS_I_ SOL_ON
179 #define SOL_PLATFORM_WINDOWS_I_ SOL_OFF
181 #elif defined(_WIN32)
182 #define SOL_PLATFORM_WINDOWS_I_ SOL_DEFAULT_ON
184 #define SOL_PLATFORM_WINDOWS_I_ SOL_DEFAULT_OFF
187 #if defined(SOL_PLATFORM_CYGWIN)
188 #if (SOL_PLATFORM_CYGWIN != 0)
189 #define SOL_PLATFORM_CYGWIN_I_ SOL_ON
191 #define SOL_PLATFORM_CYGWIN_I_ SOL_ON
193 #elif defined(__CYGWIN__)
194 #define SOL_PLATFORM_CYGWIN_I_ SOL_DEFAULT_ON
196 #define SOL_PLATFORM_CYGWIN_I_ SOL_DEFAULT_OFF
199 #if defined(SOL_PLATFORM_APPLE)
200 #if (SOL_PLATFORM_APPLE != 0)
201 #define SOL_PLATFORM_APPLE_I_ SOL_ON
203 #define SOL_PLATFORM_APPLE_I_ SOL_OFF
205 #elif defined(__APPLE__)
206 #define SOL_PLATFORM_APPLE_I_ SOL_DEFAULT_ON
208 #define SOL_PLATFORM_APPLE_I_ SOL_DEFAULT_OFF
211 #if defined(SOL_PLATFORM_UNIX)
212 #if (SOL_PLATFORM_UNIX != 0)
213 #define SOL_PLATFORM_UNIXLIKE_I_ SOL_ON
215 #define SOL_PLATFORM_UNIXLIKE_I_ SOL_OFF
217 #elif defined(__unix__)
218 #define SOL_PLATFORM_UNIXLIKE_I_ SOL_DEFAUKT_ON
220 #define SOL_PLATFORM_UNIXLIKE_I_ SOL_DEFAULT_OFF
223 #if defined(SOL_PLATFORM_LINUX)
224 #if (SOL_PLATFORM_LINUX != 0)
225 #define SOL_PLATFORM_LINUXLIKE_I_ SOL_ON
227 #define SOL_PLATFORM_LINUXLIKE_I_ SOL_OFF
229 #elif defined(__LINUX__)
230 #define SOL_PLATFORM_LINUXLIKE_I_ SOL_DEFAUKT_ON
232 #define SOL_PLATFORM_LINUXLIKE_I_ SOL_DEFAULT_OFF
235 #define SOL_PLATFORM_APPLE_IPHONE_I_ SOL_OFF
236 #define SOL_PLATFORM_BSDLIKE_I_ SOL_OFF
238 #if defined(SOL_IN_DEBUG_DETECTED)
239 #if SOL_IN_DEBUG_DETECTED != 0
240 #define SOL_DEBUG_BUILD_I_ SOL_ON
242 #define SOL_DEBUG_BUILD_I_ SOL_OFF
244 #elif !defined(NDEBUG)
245 #if SOL_IS_ON(SOL_COMPILER_VCXX) && defined(_DEBUG)
246 #define SOL_DEBUG_BUILD_I_ SOL_ON
247 #elif (SOL_IS_ON(SOL_COMPILER_CLANG) || SOL_IS_ON(SOL_COMPILER_GCC)) && !defined(__OPTIMIZE__)
248 #define SOL_DEBUG_BUILD_I_ SOL_ON
250 #define SOL_DEBUG_BUILD_I_ SOL_OFF
253 #define SOL_DEBUG_BUILD_I_ SOL_DEFAULT_OFF
254 #endif // We are in a debug mode of some sort
256 #if defined(SOL_NO_EXCEPTIONS)
257 #if (SOL_NO_EXCEPTIONS != 0)
258 #define SOL_EXCEPTIONS_I_ SOL_OFF
260 #define SOL_EXCEPTIONS_I_ SOL_ON
262 #elif SOL_IS_ON(SOL_COMPILER_VCXX)
263 #if !defined(_CPPUNWIND)
264 #define SOL_EXCEPTIONS_I_ SOL_OFF
266 #define SOL_EXCEPTIONS_I_ SOL_ON
268 #elif SOL_IS_ON(SOL_COMPILER_CLANG) || SOL_IS_ON(SOL_COMPILER_GCC)
269 #if !defined(__EXCEPTIONS)
270 #define SOL_EXCEPTIONS_I_ SOL_OFF
272 #define SOL_EXCEPTIONS_I_ SOL_ON
275 #define SOL_EXCEPTIONS_I_ SOL_DEFAULT_ON
278 #if defined(SOL_NO_RTTI)
279 #if (SOL_NO_RTTI != 0)
280 #define SOL_RTTI_I_ SOL_OFF
282 #define SOL_RTTI_I_ SOL_ON
284 #elif SOL_IS_ON(SOL_COMPILER_VCXX)
285 #if !defined(_CPPRTTI)
286 #define SOL_RTTI_I_ SOL_OFF
288 #define SOL_RTTI_I_ SOL_ON
290 #elif SOL_IS_ON(SOL_COMPILER_CLANG) || SOL_IS_ON(SOL_COMPILER_GCC)
291 #if !defined(__GXX_RTTI)
292 #define SOL_RTTI_I_ SOL_OFF
294 #define SOL_RTTI_I_ SOL_ON
297 #define SOL_RTTI_I_ SOL_DEFAULT_ON
300 #if defined(SOL_NO_THREAD_LOCAL)
301 #if SOL_NO_THREAD_LOCAL != 0
302 #define SOL_USE_THREAD_LOCAL_I_ SOL_OFF
304 #define SOL_USE_THREAD_LOCAL_I_ SOL_ON
307 #define SOL_USE_THREAD_LOCAL_I_ SOL_DEFAULT_ON
308 #endif // thread_local keyword is bjorked on some platforms
310 #if defined(SOL_ALL_SAFETIES_ON)
311 #if SOL_ALL_SAFETIES_ON != 0
312 #define SOL_ALL_SAFETIES_ON_I_ SOL_ON
314 #define SOL_ALL_SAFETIES_ON_I_ SOL_OFF
317 #define SOL_ALL_SAFETIES_ON_I_ SOL_DEFAULT_OFF
320 #if defined(SOL_SAFE_GETTER)
321 #if SOL_SAFE_GETTER != 0
322 #define SOL_SAFE_GETTER_I_ SOL_ON
324 #define SOL_SAFE_GETTER_I_ SOL_OFF
327 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
328 #define SOL_SAFE_GETTER_I_ SOL_ON
329 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
330 #define SOL_SAFE_GETTER_I_ SOL_DEFAULT_ON
332 #define SOL_SAFE_GETTER_I_ SOL_DEFAULT_OFF
336 #if defined(SOL_SAFE_USERTYPE)
337 #if SOL_SAFE_USERTYPE != 0
338 #define SOL_SAFE_USERTYPE_I_ SOL_ON
340 #define SOL_SAFE_USERTYPE_I_ SOL_OFF
343 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
344 #define SOL_SAFE_USERTYPE_I_ SOL_ON
345 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
346 #define SOL_SAFE_USERTYPE_I_ SOL_DEFAULT_ON
348 #define SOL_SAFE_USERTYPE_I_ SOL_DEFAULT_OFF
352 #if defined(SOL_SAFE_REFERENCES)
353 #if SOL_SAFE_REFERENCES != 0
354 #define SOL_SAFE_REFERENCES_I_ SOL_ON
356 #define SOL_SAFE_REFERENCES_I_ SOL_OFF
359 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
360 #define SOL_SAFE_REFERENCES_I_ SOL_ON
361 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
362 #define SOL_SAFE_REFERENCES_I_ SOL_DEFAULT_ON
364 #define SOL_SAFE_REFERENCES_I_ SOL_DEFAULT_OFF
368 #if defined(SOL_SAFE_FUNCTIONS)
369 #if SOL_SAFE_FUNCTIONS != 0
370 #define SOL_SAFE_FUNCTION_OBJECTS_I_ SOL_ON
372 #define SOL_SAFE_FUNCTION_OBJECTS_I_ SOL_OFF
374 #elif defined (SOL_SAFE_FUNCTION_OBJECTS)
375 #if SOL_SAFE_FUNCTION_OBJECTS != 0
376 #define SOL_SAFE_FUNCTION_OBJECTS_I_ SOL_ON
378 #define SOL_SAFE_FUNCTION_OBJECTS_I_ SOL_OFF
381 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
382 #define SOL_SAFE_FUNCTION_OBJECTS_I_ SOL_ON
383 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
384 #define SOL_SAFE_FUNCTION_OBJECTS_I_ SOL_DEFAULT_ON
386 #define SOL_SAFE_FUNCTION_OBJECTS_I_ SOL_DEFAULT_OFF
390 #if defined(SOL_SAFE_FUNCTION_CALLS)
391 #if SOL_SAFE_FUNCTION_CALLS != 0
392 #define SOL_SAFE_FUNCTION_CALLS_I_ SOL_ON
394 #define SOL_SAFE_FUNCTION_CALLS_I_ SOL_OFF
397 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
398 #define SOL_SAFE_FUNCTION_CALLS_I_ SOL_ON
399 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
400 #define SOL_SAFE_FUNCTION_CALLS_I_ SOL_DEFAULT_ON
402 #define SOL_SAFE_FUNCTION_CALLS_I_ SOL_DEFAULT_OFF
406 #if defined(SOL_SAFE_PROXIES)
407 #if SOL_SAFE_PROXIES != 0
408 #define SOL_SAFE_PROXIES_I_ SOL_ON
410 #define SOL_SAFE_PROXIES_I_ SOL_OFF
413 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
414 #define SOL_SAFE_PROXIES_I_ SOL_ON
415 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
416 #define SOL_SAFE_PROXIES_I_ SOL_DEFAULT_ON
418 #define SOL_SAFE_PROXIES_I_ SOL_DEFAULT_OFF
422 #if defined(SOL_SAFE_NUMERICS)
423 #if SOL_SAFE_NUMERICS != 0
424 #define SOL_SAFE_NUMERICS_I_ SOL_ON
426 #define SOL_SAFE_NUMERICS_I_ SOL_OFF
429 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
430 #define SOL_SAFE_NUMERICS_I_ SOL_ON
431 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
432 #define SOL_SAFE_NUMERICS_I_ SOL_DEFAULT_ON
434 #define SOL_SAFE_NUMERICS_I_ SOL_DEFAULT_OFF
438 #if defined(SOL_ALL_INTEGER_VALUES_FIT)
439 #if (SOL_ALL_INTEGER_VALUES_FIT != 0)
440 #define SOL_ALL_INTEGER_VALUES_FIT_I_ SOL_ON
442 #define SOL_ALL_INTEGER_VALUES_FIT_I_ SOL_OFF
444 #elif !SOL_IS_DEFAULT_OFF(SOL_SAFE_NUMERICS) && SOL_IS_OFF(SOL_SAFE_NUMERICS)
446 #define SOL_ALL_INTEGER_VALUES_FIT_I_ SOL_DEFAULT_ON
449 #define SOL_ALL_INTEGER_VALUES_FIT_I_ SOL_DEFAULT_OFF
452 #if defined(SOL_SAFE_STACK_CHECK)
453 #if SOL_SAFE_STACK_CHECK != 0
454 #define SOL_SAFE_STACK_CHECK_I_ SOL_ON
456 #define SOL_SAFE_STACK_CHECK_I_ SOL_OFF
459 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
460 #define SOL_SAFE_STACK_CHECK_I_ SOL_ON
461 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
462 #define SOL_SAFE_STACK_CHECK_I_ SOL_DEFAULT_ON
464 #define SOL_SAFE_STACK_CHECK_I_ SOL_DEFAULT_OFF
468 #if defined(SOL_NO_CHECK_NUMBER_PRECISION)
469 #if SOL_NO_CHECK_NUMBER_PRECISION != 0
470 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_OFF
472 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_ON
474 #elif defined(SOL_NO_CHECKING_NUMBER_PRECISION)
475 #if SOL_NO_CHECKING_NUMBER_PRECISION != 0
476 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_OFF
478 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_ON
481 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
482 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_ON
483 #elif SOL_IS_ON(SOL_SAFE_NUMERICS)
484 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_ON
485 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
486 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_DEFAULT_ON
488 #define SOL_NUMBER_PRECISION_CHECKS_I_ SOL_DEFAULT_OFF
492 #if defined(SOL_STRINGS_ARE_NUMBERS)
493 #if (SOL_STRINGS_ARE_NUMBERS != 0)
494 #define SOL_STRINGS_ARE_NUMBERS_I_ SOL_ON
496 #define SOL_STRINGS_ARE_NUMBERS_I_ SOL_OFF
499 #define SOL_STRINGS_ARE_NUMBERS_I_ SOL_DEFAULT_OFF
502 #if defined(SOL_ENABLE_INTEROP)
503 #if SOL_ENABLE_INTEROP != 0
504 #define SOL_USE_INTEROP_I_ SOL_ON
506 #define SOL_USE_INTEROP_I_ SOL_OFF
508 #elif defined(SOL_USE_INTEROP)
509 #if SOL_USE_INTEROP != 0
510 #define SOL_USE_INTEROP_I_ SOL_ON
512 #define SOL_USE_INTEROP_I_ SOL_OFF
515 #define SOL_USE_INTEROP_I_ SOL_DEFAULT_OFF
518 #if defined(SOL_NO_NIL)
519 #if (SOL_NO_NIL != 0)
520 #define SOL_NIL_I_ SOL_OFF
522 #define SOL_NIL_I_ SOL_ON
524 #elif defined(__MAC_OS_X_VERSION_MAX_ALLOWED) || defined(__OBJC__) || defined(nil)
525 #define SOL_NIL_I_ SOL_DEFAULT_OFF
527 #define SOL_NIL_I_ SOL_DEFAULT_ON
530 #if defined(SOL_USERTYPE_TYPE_BINDING_INFO)
531 #if (SOL_USERTYPE_TYPE_BINDING_INFO != 0)
532 #define SOL_USERTYPE_TYPE_BINDING_INFO_I_ SOL_ON
534 #define SOL_USERTYPE_TYPE_BINDING_INFO_I_ SOL_OFF
537 #define SOL_USERTYPE_TYPE_BINDING_INFO_I_ SOL_DEFAULT_ON
538 #endif // We should generate a my_type.__type table with lots of class information for usertypes
540 #if defined(SOL_AUTOMAGICAL_TYPES_BY_DEFAULT)
541 #if (SOL_AUTOMAGICAL_TYPES_BY_DEFAULT != 0)
542 #define SOL_DEFAULT_AUTOMAGICAL_USERTYPES_I_ SOL_ON
544 #define SOL_DEFAULT_AUTOMAGICAL_USERTYPES_I_ SOL_OFF
546 #elif defined(SOL_DEFAULT_AUTOMAGICAL_USERTYPES)
547 #if (SOL_DEFAULT_AUTOMAGICAL_USERTYPES != 0)
548 #define SOL_DEFAULT_AUTOMAGICAL_USERTYPES_I_ SOL_ON
550 #define SOL_DEFAULT_AUTOMAGICAL_USERTYPES_I_ SOL_OFF
553 #define SOL_DEFAULT_AUTOMAGICAL_USERTYPES_I_ SOL_DEFAULT_ON
554 #endif // make is_automagical on/off by default
556 #if defined(SOL_STD_VARIANT)
557 #if (SOL_STD_VARIANT != 0)
558 #define SOL_STD_VARIANT_I_ SOL_ON
560 #define SOL_STD_VARIANT_I_ SOL_OFF
563 #if SOL_IS_ON(SOL_COMPILER_CLANG) && SOL_IS_ON(SOL_PLATFORM_APPLE)
564 #if defined(__has_include)
565 #if __has_include(<variant>)
566 #define SOL_STD_VARIANT_I_ SOL_DEFAULT_ON
568 #define SOL_STD_VARIANT_I_ SOL_DEFAULT_OFF
571 #define SOL_STD_VARIANT_I_ SOL_DEFAULT_OFF
574 #define SOL_STD_VARIANT_I_ SOL_DEFAULT_ON
576 #endif // make is_automagical on/off by default
578 #if defined(SOL_NOEXCEPT_FUNCTION_TYPE)
579 #if (SOL_NOEXCEPT_FUNCTION_TYPE != 0)
580 #define SOL_USE_NOEXCEPT_FUNCTION_TYPE_I_ SOL_ON
582 #define SOL_USE_NOEXCEPT_FUNCTION_TYPE_I_ SOL_OFF
585 #if defined(__cpp_noexcept_function_type)
586 #define SOL_USE_NOEXCEPT_FUNCTION_TYPE_I_ SOL_ON
587 #elif SOL_IS_ON(SOL_COMPILER_VCXX) && (defined(_MSVC_LANG) && (_MSVC_LANG < 201403L))
593 #define SOL_USE_NOEXCEPT_FUNCTION_TYPE_I_ SOL_OFF
595 #define SOL_USE_NOEXCEPT_FUNCTION_TYPE_I_ SOL_DEFAULT_ON
597 #endif // noexcept is part of a function's type
599 #if defined(SOL_STACK_STRING_OPTIMIZATION_SIZE) && SOL_STACK_STRING_OPTIMIZATION_SIZE > 0
600 #define SOL_OPTIMIZATION_STRING_CONVERSION_STACK_SIZE_I_ SOL_STACK_STRING_OPTIMIZATION_SIZE
602 #define SOL_OPTIMIZATION_STRING_CONVERSION_STACK_SIZE_I_ 1024
605 #if defined(SOL_ID_SIZE) && SOL_ID_SIZE > 0
606 #define SOL_ID_SIZE_I_ SOL_ID_SIZE
608 #define SOL_ID_SIZE_I_ 512
611 #if defined(LUA_IDSIZE) && LUA_IDSIZE > 0
612 #define SOL_FILE_ID_SIZE_I_ LUA_IDSIZE
613 #elif defined(SOL_ID_SIZE) && SOL_ID_SIZE > 0
614 #define SOL_FILE_ID_SIZE_I_ SOL_FILE_ID_SIZE
616 #define SOL_FILE_ID_SIZE_I_ 2048
619 #if defined(SOL_PRINT_ERRORS)
620 #if (SOL_PRINT_ERRORS != 0)
621 #define SOL_PRINT_ERRORS_I_ SOL_ON
623 #define SOL_PRINT_ERRORS_I_ SOL_OFF
626 #if SOL_IS_ON(SOL_ALL_SAFETIES_ON)
627 #define SOL_PRINT_ERRORS_I_ SOL_ON
628 #elif SOL_IS_ON(SOL_DEBUG_BUILD)
629 #define SOL_PRINT_ERRORS_I_ SOL_DEFAULT_ON
631 #define SOL_PRINT_ERRORS_I_ SOL_OFF
635 #if defined(SOL_DEFAULT_PASS_ON_ERROR)
636 #if (SOL_DEFAULT_PASS_ON_ERROR != 0)
637 #define SOL_DEFAULT_PASS_ON_ERROR_I_ SOL_ON
639 #define SOL_DEFAULT_PASS_ON_ERROR_I_ SOL_OFF
642 #define SOL_DEFAULT_PASS_ON_ERROR_I_ SOL_DEFAULT_OFF
645 #if defined(SOL_USING_CXX_LUA)
646 #if (SOL_USING_CXX_LUA != 0)
647 #define SOL_USE_CXX_LUA_I_ SOL_ON
649 #define SOL_USE_CXX_LUA_I_ SOL_OFF
651 #elif defined(SOL_USE_CXX_LUA)
652 #if (SOL_USE_CXX_LUA != 0)
653 #define SOL_USE_CXX_LUA_I_ SOL_ON
655 #define SOL_USE_CXX_LUA_I_ SOL_OFF
658 #define SOL_USE_CXX_LUA_I_ SOL_DEFAULT_OFF
661 #if defined(SOL_USING_CXX_LUAJIT)
662 #if (SOL_USING_CXX_LUA != 0)
663 #define SOL_USE_CXX_LUAJIT_I_ SOL_ON
665 #define SOL_USE_CXX_LUAJIT_I_ SOL_OFF
667 #elif defined(SOL_USE_CXX_LUAJIT)
668 #if (SOL_USE_CXX_LUA != 0)
669 #define SOL_USE_CXX_LUAJIT_I_ SOL_ON
671 #define SOL_USE_CXX_LUAJIT_I_ SOL_OFF
674 #define SOL_USE_CXX_LUAJIT_I_ SOL_DEFAULT_OFF
677 #if defined(SOL_NO_LUA_HPP)
678 #if (SOL_NO_LUA_HPP != 0)
679 #define SOL_USE_LUA_HPP_I_ SOL_OFF
681 #define SOL_USE_LUA_HPP_I_ SOL_ON
683 #elif defined(SOL_USING_CXX_LUA)
684 #define SOL_USE_LUA_HPP_I_ SOL_OFF
685 #elif defined(__has_include)
686 #if __has_include(<lua.hpp>)
687 #define SOL_USE_LUA_HPP_I_ SOL_ON
689 #define SOL_USE_LUA_HPP_I_ SOL_OFF
692 #define SOL_USE_LUA_HPP_I_ SOL_DEFAULT_ON
695 #if defined(SOL_CONTAINERS_START)
696 #define SOL_CONTAINER_START_INDEX_I_ SOL_CONTAINERS_START
697 #elif defined(SOL_CONTAINERS_START_INDEX)
698 #define SOL_CONTAINER_START_INDEX_I_ SOL_CONTAINERS_START_INDEX
699 #elif defined(SOL_CONTAINER_START_INDEX)
700 #define SOL_CONTAINER_START_INDEX_I_ SOL_CONTAINER_START_INDEX
702 #define SOL_CONTAINER_START_INDEX_I_ 1
705 #if defined (SOL_NO_MEMORY_ALIGNMENT)
706 #if (SOL_NO_MEMORY_ALIGNMENT != 0)
707 #define SOL_ALIGN_MEMORY_I_ SOL_OFF
709 #define SOL_ALIGN_MEMORY_I_ SOL_ON
712 #define SOL_ALIGN_MEMORY_I_ SOL_DEFAULT_ON
715 #if defined(SOL_USE_BOOST)
716 #if (SOL_USE_BOOST != 0)
717 #define SOL_USE_BOOST_I_ SOL_ON
719 #define SOL_USE_BOOST_I_ SOL_OFF
722 #define SOL_USE_BOOST_I_ SOL_DEFAULT_OFF
725 #if defined(SOL_USE_UNSAFE_BASE_LOOKUP)
726 #if (SOL_USE_UNSAFE_BASE_LOOKUP != 0)
727 #define SOL_USE_UNSAFE_BASE_LOOKUP_I_ SOL_ON
729 #define SOL_USE_UNSAFE_BASE_LOOKUP_I_ SOL_OFF
732 #define SOL_USE_UNSAFE_BASE_LOOKUP_I_ SOL_DEFAULT_OFF
735 #if defined(SOL_INSIDE_UNREAL)
736 #if (SOL_INSIDE_UNREAL != 0)
737 #define SOL_INSIDE_UNREAL_ENGINE_I_ SOL_ON
739 #define SOL_INSIDE_UNREAL_ENGINE_I_ SOL_OFF
742 #if defined(UE_BUILD_DEBUG) || defined(UE_BUILD_DEVELOPMENT) || defined(UE_BUILD_TEST) || defined(UE_BUILD_SHIPPING) || defined(UE_SERVER)
743 #define SOL_INSIDE_UNREAL_ENGINE_I_ SOL_DEFAULT_ON
745 #define SOL_INSIDE_UNREAL_ENGINE_I_ SOL_DEFAULT_OFF
749 #if defined(SOL_NO_COMPAT)
750 #if (SOL_NO_COMPAT != 0)
751 #define SOL_USE_COMPATIBILITY_LAYER_I_ SOL_OFF
753 #define SOL_USE_COMPATIBILITY_LAYER_I_ SOL_ON
756 #define SOL_USE_COMPATIBILITY_LAYER_I_ SOL_DEFAULT_ON
759 #if defined(SOL_GET_FUNCTION_POINTER_UNSAFE)
760 #if (SOL_GET_FUNCTION_POINTER_UNSAFE != 0)
761 #define SOL_GET_FUNCTION_POINTER_UNSAFE_I_ SOL_ON
763 #define SOL_GET_FUNCTION_POINTER_UNSAFE_I_ SOL_OFF
766 #define SOL_GET_FUNCTION_POINTER_UNSAFE_I_ SOL_DEFAULT_OFF
769 #if defined(SOL_FUNCTION_CALL_VALUE_SEMANTICS)
770 #if (SOL_FUNCTION_CALL_VALUE_SEMANTICS != 0)
771 #define SOL_FUNCTION_CALL_VALUE_SEMANTICS_I_ SOL_ON
773 #define SOL_FUNCTION_CALL_VALUE_SEMANTICS_I_ SOL_OFF
776 #define SOL_FUNCTION_CALL_VALUE_SEMANTICS_I_ SOL_DEFAULT_OFF
779 #if defined(SOL_MINGW_CCTYPE_IS_POISONED)
780 #if (SOL_MINGW_CCTYPE_IS_POISONED != 0)
781 #define SOL_MINGW_CCTYPE_IS_POISONED_I_ SOL_ON
783 #define SOL_MINGW_CCTYPE_IS_POISONED_I_ SOL_OFF
785 #elif SOL_IS_ON(SOL_COMPILER_MINGW) && defined(__GNUC__) && (__GNUC__ < 6)
787 #define SOL_MINGW_CCTYPE_IS_POISONED_I_ SOL_DEFAULT_ON
789 #define SOL_MINGW_CCTYPE_IS_POISONED_I_ SOL_DEFAULT_OFF
792 #if defined(SOL_CHAR8_T)
793 #if (SOL_CHAR8_T != 0)
794 #define SOL_CHAR8_T_I_ SOL_ON
796 #define SOL_CHAR8_T_I_ SOL_OFF
799 #if defined(__cpp_char8_t)
800 #define SOL_CHAR8_T_I_ SOL_DEFAULT_ON
802 #define SOL_CHAR8_T_I_ SOL_DEFAULT_OFF
806 #if SOL_IS_ON(SOL_USE_BOOST)
807 #include <boost/version.hpp>
809 #if BOOST_VERSION >= 107500 // Since Boost 1.75.0 boost::none is constexpr
810 #define SOL_BOOST_NONE_CONSTEXPR_I_ constexpr
812 #define SOL_BOOST_NONE_CONSTEXPR_I_ const
813 #endif // BOOST_VERSION
816 #define SOL_BOOST_NONE_CONSTEXPR_I_ constexpr
821 #define SOL2_CI_I_ SOL_ON
823 #define SOL2_CI_I_ SOL_OFF
826 #define SOL2_CI_I_ SOL_DEFAULT_OFF
829 #if defined(SOL_C_ASSERT)
830 #define SOL_USER_C_ASSERT_I_ SOL_ON
832 #define SOL_USER_C_ASSERT_I_ SOL_DEFAULT_OFF
835 #if defined(SOL_M_ASSERT)
836 #define SOL_USER_M_ASSERT_I_ SOL_ON
838 #define SOL_USER_M_ASSERT_I_ SOL_DEFAULT_OFF
843 #if defined(SOL_PROLOGUE_I_)
844 #error "[sol2] Library Prologue was already included in translation unit and not properly ended with an epilogue."
847 #define SOL_PROLOGUE_I_ 1
849 #if SOL_IS_ON(SOL_BUILD_CXX_MODE)
850 #define _FWD(...) static_cast<decltype( __VA_ARGS__ )&&>( __VA_ARGS__ )
852 #if SOL_IS_ON(SOL_COMPILER_GCC) || SOL_IS_ON(SOL_COMPILER_CLANG)
853 #define _MOVE(...) static_cast<__typeof( __VA_ARGS__ )&&>( __VA_ARGS__ )
855 #include <type_traits>
857 #define _MOVE(...) static_cast<::std::remove_reference_t<( __VA_ARGS__ )>&&>( __VA_OPT__(,) )
865 #if !defined(SOL_PROLOGUE_I_)
866 #error "[sol2] Library Prologue is missing from this translation unit."
868 #undef SOL_PROLOGUE_I_
871 #if SOL_IS_ON(SOL_BUILD_CXX_MODE)
882 #define SOL_DLL_I_ SOL_ON
884 #define SOL_DLL_I_ SOL_OFF
886 #elif SOL_IS_ON(SOL_COMPILER_VCXX) && (defined(DLL_) || defined(_DLL))
887 #define SOL_DLL_I_ SOL_DEFAULT_ON
889 #define SOL_DLL_I_ SOL_DEFAULT_OFF
890 #endif // DLL definition
892 #if defined(SOL_HEADER_ONLY)
893 #if (SOL_HEADER_ONLY != 0)
894 #define SOL_HEADER_ONLY_I_ SOL_ON
896 #define SOL_HEADER_ONLY_I_ SOL_OFF
899 #define SOL_HEADER_ONLY_I_ SOL_DEFAULT_OFF
900 #endif // Header only library
902 #if defined(SOL_BUILD)
904 #define SOL_BUILD_I_ SOL_ON
906 #define SOL_BUILD_I_ SOL_OFF
908 #elif SOL_IS_ON(SOL_HEADER_ONLY)
909 #define SOL_BUILD_I_ SOL_DEFAULT_OFF
911 #define SOL_BUILD_I_ SOL_DEFAULT_ON
914 #if defined(SOL_UNITY_BUILD)
915 #if (SOL_UNITY_BUILD != 0)
916 #define SOL_UNITY_BUILD_I_ SOL_ON
918 #define SOL_UNITY_BUILD_I_ SOL_OFF
921 #define SOL_UNITY_BUILD_I_ SOL_DEFAULT_OFF
922 #endif // Header only library
924 #if defined(SOL_C_FUNCTION_LINKAGE)
925 #define SOL_C_FUNCTION_LINKAGE_I_ SOL_C_FUNCTION_LINKAGE
927 #if SOL_IS_ON(SOL_BUILD_CXX_MODE)
929 #define SOL_C_FUNCTION_LINKAGE_I_ extern "C"
932 #define SOL_C_FUNCTION_LINKAGE_I_
934 #endif // Linkage specification for C functions
936 #if defined(SOL_API_LINKAGE)
937 #define SOL_API_LINKAGE_I_ SOL_API_LINKAGE
939 #if SOL_IS_ON(SOL_DLL)
940 #if SOL_IS_ON(SOL_COMPILER_VCXX) || SOL_IS_ON(SOL_PLATFORM_WINDOWS) || SOL_IS_ON(SOL_PLATFORM_CYGWIN)
942 #if SOL_IS_ON(SOL_BUILD)
944 #if SOL_IS_ON(SOL_COMPILER_GCC)
946 #define SOL_API_LINKAGE_I_ __attribute__((dllexport))
949 #define SOL_API_LINKAGE_I_ __declspec(dllexport)
952 #if SOL_IS_ON(SOL_COMPILER_GCC)
953 #define SOL_API_LINKAGE_I_ __attribute__((dllimport))
955 #define SOL_API_LINKAGE_I_ __declspec(dllimport)
960 #define SOL_API_LINKAGE_I_ extern
962 #elif SOL_IS_ON(SOL_UNITY_BUILD)
964 #if SOL_IS_ON(SOL_HEADER_ONLY)
966 #define SOL_API_LINKAGE_I_ inline
969 #define SOL_API_LINKAGE_I_ extern
973 #if SOL_IS_ON(SOL_BUILD_CXX_MODE)
974 #define SOL_API_LINKAGE_I_
976 #define SOL_API_LINKAGE_I_ extern
979 #endif // Build definitions
981 #if defined(SOL_PUBLIC_FUNC_DECL)
982 #define SOL_PUBLIC_FUNC_DECL_I_ SOL_PUBLIC_FUNC_DECL
984 #define SOL_PUBLIC_FUNC_DECL_I_ SOL_API_LINKAGE_I_
987 #if defined(SOL_INTERNAL_FUNC_DECL_)
988 #define SOL_INTERNAL_FUNC_DECL_I_ SOL_INTERNAL_FUNC_DECL_
990 #define SOL_INTERNAL_FUNC_DECL_I_ SOL_API_LINKAGE_I_
993 #if defined(SOL_PUBLIC_FUNC_DEF)
994 #define SOL_PUBLIC_FUNC_DEF_I_ SOL_PUBLIC_FUNC_DEF
996 #define SOL_PUBLIC_FUNC_DEF_I_ SOL_API_LINKAGE_I_
999 #if defined(SOL_INTERNAL_FUNC_DEF)
1000 #define SOL_INTERNAL_FUNC_DEF_I_ SOL_INTERNAL_FUNC_DEF
1002 #define SOL_INTERNAL_FUNC_DEF_I_ SOL_API_LINKAGE_I_
1005 #if defined(SOL_FUNC_DECL)
1006 #define SOL_FUNC_DECL_I_ SOL_FUNC_DECL
1007 #elif SOL_IS_ON(SOL_HEADER_ONLY)
1008 #define SOL_FUNC_DECL_I_
1009 #elif SOL_IS_ON(SOL_DLL)
1010 #if SOL_IS_ON(SOL_COMPILER_VCXX)
1011 #if SOL_IS_ON(SOL_BUILD)
1012 #define SOL_FUNC_DECL_I_ extern __declspec(dllexport)
1014 #define SOL_FUNC_DECL_I_ extern __declspec(dllimport)
1016 #elif SOL_IS_ON(SOL_COMPILER_GCC) || SOL_IS_ON(SOL_COMPILER_CLANG)
1017 #define SOL_FUNC_DECL_I_ extern __attribute__((visibility("default")))
1019 #define SOL_FUNC_DECL_I_ extern
1023 #if defined(SOL_FUNC_DEFN)
1024 #define SOL_FUNC_DEFN_I_ SOL_FUNC_DEFN
1025 #elif SOL_IS_ON(SOL_HEADER_ONLY)
1026 #define SOL_FUNC_DEFN_I_ inline
1027 #elif SOL_IS_ON(SOL_DLL)
1028 #if SOL_IS_ON(SOL_COMPILER_VCXX)
1029 #if SOL_IS_ON(SOL_BUILD)
1030 #define SOL_FUNC_DEFN_I_ __declspec(dllexport)
1032 #define SOL_FUNC_DEFN_I_ __declspec(dllimport)
1034 #elif SOL_IS_ON(SOL_COMPILER_GCC) || SOL_IS_ON(SOL_COMPILER_CLANG)
1035 #define SOL_FUNC_DEFN_I_ __attribute__((visibility("default")))
1037 #define SOL_FUNC_DEFN_I_
1041 #if defined(SOL_HIDDEN_FUNC_DECL)
1042 #define SOL_HIDDEN_FUNC_DECL_I_ SOL_HIDDEN_FUNC_DECL
1043 #elif SOL_IS_ON(SOL_HEADER_ONLY)
1044 #define SOL_HIDDEN_FUNC_DECL_I_
1045 #elif SOL_IS_ON(SOL_DLL)
1046 #if SOL_IS_ON(SOL_COMPILER_VCXX)
1047 #if SOL_IS_ON(SOL_BUILD)
1048 #define SOL_HIDDEN_FUNC_DECL_I_ extern __declspec(dllexport)
1050 #define SOL_HIDDEN_FUNC_DECL_I_ extern __declspec(dllimport)
1052 #elif SOL_IS_ON(SOL_COMPILER_GCC) || SOL_IS_ON(SOL_COMPILER_CLANG)
1053 #define SOL_HIDDEN_FUNC_DECL_I_ extern __attribute__((visibility("default")))
1055 #define SOL_HIDDEN_FUNC_DECL_I_ extern
1059 #if defined(SOL_HIDDEN_FUNC_DEFN)
1060 #define SOL_HIDDEN_FUNC_DEFN_I_ SOL_HIDDEN_FUNC_DEFN
1061 #elif SOL_IS_ON(SOL_HEADER_ONLY)
1062 #define SOL_HIDDEN_FUNC_DEFN_I_ inline
1063 #elif SOL_IS_ON(SOL_DLL)
1064 #if SOL_IS_ON(SOL_COMPILER_VCXX)
1065 #if SOL_IS_ON(SOL_BUILD)
1066 #define SOL_HIDDEN_FUNC_DEFN_I_
1068 #define SOL_HIDDEN_FUNC_DEFN_I_
1070 #elif SOL_IS_ON(SOL_COMPILER_GCC) || SOL_IS_ON(SOL_COMPILER_CLANG)
1071 #define SOL_HIDDEN_FUNC_DEFN_I_ __attribute__((visibility("hidden")))
1073 #define SOL_HIDDEN_FUNC_DEFN_I_
1082 #include <type_traits>
1083 #include <string_view>
1085 #if SOL_IS_ON(SOL_USE_CXX_LUA) || SOL_IS_ON(SOL_USE_CXX_LUAJIT)
1091 #endif // C++ Mangling for Lua vs. Not
1105 template <
typename A>
1113 template <
typename,
typename>
1116 template <
bool,
typename>
1124 template <
typename base_type>
1138 template <
typename T,
typename base_type>
1140 template <
typename T>
1142 template <
typename T>
1145 template <
typename base_type>
1150 template <
typename base_t>
1156 template <
typename T,
bool>
1158 template <
typename T,
bool,
typename H>
1172 #if SOL_IS_ON(SOL_SAFE_FUNCTION_OBJECTS)
1188 #if SOL_IS_ON(SOL_SAFE_FUNCTION_OBJECTS)
1194 template <
typename base_t>
1196 template <
typename base_t>
1198 template <
typename base_t>
1200 template <
typename base_t>
1202 template <
typename base_t>
1204 template <
typename base_t>
1206 template <
typename base_t>
1237 template <
typename T>
1239 template <
typename T>
1241 template <
typename T>
1243 template <
typename T>
1245 template <
typename T>
1247 template <
typename T>
1249 template <
typename T>
1251 template <
typename F,
typename... Policies>
1254 template <
typename T>
1256 template <
typename T>
1259 template <
typename... Args>
1263 return sizeof...(Args);
1267 template <
typename T>
1272 template <
typename T>
1277 template <
typename T>
1282 template <
typename T>
1289 #if SOL_IS_OFF(SOL_USE_BOOST)
1301 #define SOL_BASE_CLASSES(T, ...) \
1304 struct base<T> : std::true_type { \
1305 typedef ::sol::types<__VA_ARGS__> type; \
1308 void a_sol3_detail_function_decl_please_no_collide()
1309 #define SOL_DERIVED_CLASSES(T, ...) \
1312 struct derive<T> : std::true_type { \
1313 typedef ::sol::types<__VA_ARGS__> type; \
1316 void a_sol3_detail_function_decl_please_no_collide()
1318 #endif // SOL_FORWARD_HPP
1321 #endif // SOL_SINGLE_INCLUDE_FORWARD_HPP
basic_protected_function< main_reference, false, reference > main_safe_function
safe_function protected_function
protected_function_result safe_function_result
basic_protected_function< stack_reference, false, reference > stack_safe_function
span_CONFIG_SIZE_TYPE size_t
std::make_index_sequence< sizeof...(Args)> indices
integral_constant< bool, false > false_type
basic_function< stack_reference, false > stack_unsafe_function
make_integer_sequence< size_t, N > make_index_sequence
basic_function< reference, false > unsafe_function
int(lua_State *, int, type, type, const char *) check_handler_type
main_safe_function main_protected_function
basic_function< stack_reference, true > stack_aligned_unsafe_function
basic_function< main_reference, false > main_unsafe_function
basic_protected_function< reference, false, reference > safe_function
basic_protected_function< stack_reference, true, reference > stack_aligned_safe_function
stack_safe_function stack_protected_function
static constexpr std::size_t size()
plotjuggler
Author(s): Davide Faconti
autogenerated on Mon Nov 11 2024 03:23:44