libscratchcpp
A library for C++ based Scratch project players
Loading...
Searching...
No Matches
global.h
Go to the documentation of this file.
1// SPDX-License-Identifier: Apache-2.0
2
3#ifndef LIBSCRATCHCPP_GLOBAL_H
4#define LIBSCRATCHCPP_GLOBAL_H
5
6#if defined(_MSC_VER) || defined(WIN64) || defined(_WIN64) || defined(__WIN64__) || defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__NT__)
7#define DECL_EXPORT __declspec(dllexport)
8#define DECL_IMPORT __declspec(dllimport)
9#else
10#define DECL_EXPORT __attribute__((visibility("default")))
11#define DECL_IMPORT __attribute__((visibility("default")))
12#endif
13
14#if defined(LIBSCRATCHCPP_LIBRARY)
15#define LIBSCRATCHCPP_EXPORT DECL_EXPORT
16#else
17#define LIBSCRATCHCPP_EXPORT DECL_IMPORT
18#endif
19
20#include <string>
21
23namespace libscratchcpp
24{
25
26class Compiler;
27class CompilerValue;
28class Block;
29class Value;
30
37
43using MonitorNameFunc = const std::string &(*)(Block *);
44
50using MonitorChangeFunc = void (*)(Block *, const Value &newValue);
51
58
59} // namespace libscratchcpp
60
61#endif // LIBSCRATCHCPP_GLOBAL_H
The Block class represents a Scratch block.
Definition block.h:24
The CompilerValue class represents a local value in compiled code.
Definition compilervalue.h:14
The Compiler class provides API for compiling Scratch scripts.
Definition compiler.h:33
The Value class represents a Scratch value.
Definition value.h:22
The main namespace of the library.
Definition asset.h:10
const std::string &(*)(Block *) MonitorNameFunc
Definition global.h:43
CompilerValue *(*)(Compiler *vm) HatPredicateCompileFunc
Definition global.h:57
void(*)(Block *, const Value &newValue) MonitorChangeFunc
Definition global.h:50
CompilerValue *(*)(Compiler *) BlockComp
Definition global.h:36