ArkScript
A small, fast, functional and scripting language for video games
Module.hpp
Go to the documentation of this file.
1
#ifndef INCLUDE_ARK_MODULE_HPP
2
#define INCLUDE_ARK_MODULE_HPP
3
4
#include <
Ark/VM/VM.hpp
>
5
#include <
Ark/TypeChecker.hpp
>
6
7
namespace
Ark
8
{
9
struct
mapping
10
{
11
const
char
*
name
;
12
Value
(*
value
)(std::vector<Value>&,
VM
*);
13
};
14
}
15
16
#undef ARK_API
17
18
#ifdef ARK_OS_WINDOWS
19
// Windows compilers need specific (and different) keywords for export and import
20
# define ARK_API extern "C" __declspec(dllexport)
21
#else
// Linux, FreeBSD, Mac OS X
22
# if __GNUC__ >= 4
23
// GCC 4 has special keywords for showing/hiding symbols,
24
// the same keyword is used for both importing and exporting
25
# define ARK_API extern "C" __attribute__((__visibility__("default")))
26
# else
27
// GCC < 4 has no mechanism to explicitely hide symbols, everything's exported
28
# define ARK_API extern "C"
29
# endif
30
#endif
31
32
#endif
TypeChecker.hpp
VM.hpp
The ArkScript virtual machine.
Ark::VM
The ArkScript virtual machine, executing ArkScript bytecode.
Definition
VM.hpp:44
Ark::Value
Definition
Value.hpp:60
Ark
Definition
Builtins.hpp:21
Ark::mapping
Definition
Module.hpp:10
Ark::mapping::name
const char * name
Definition
Module.hpp:11
Ark::mapping::value
Value(* value)(std::vector< Value > &, VM *)
Definition
Module.hpp:12
include
Ark
Module.hpp
Generated on Wed Jan 15 2025 19:51:44 for ArkScript by
1.12.0