namespace jnc

namespace jnc {

// enums

enum {
    RegexEofChar = 256,
};

enum AccessKind;
enum BinOpKind;
enum ClassPtrTypeKind;
bitflag enum ClassTypeFlags;
enum ClassTypeKind;
enum DataPtrTypeKind;
bitflag enum DynamicLayoutMode;
enum DynamicSectionKind;
bitflag enum EnumTypeFlags;
enum FunctionKind;
bitflag enum FunctionKindFlags;
enum FunctionPtrTypeKind;
bitflag enum FunctionTypeFlags;
bitflag enum ModuleCompileFlags;
enum ModuleCompileState;
bitflag enum ModuleItemFlags;
enum ModuleItemKind;
enum NamespaceKind;
bitflag enum PropertyFlag;
enum PropertyKind;
enum PropertyPtrTypeKind;
bitflag enum PropertyTypeFlags;
bitflag enum PtrTypeFlags;
bitflag enum RegexExecFlags;
enum RegexExecResult;
bitflag enum RegexFlags;
enum RegexKind;
enum StorageKind;
enum StructTypeKind;
bitflag enum TypeFlags;
enum TypeKind;
bitflag enum TypeKindFlags;
enum UnOpKind;

// structs

struct GcStats;
struct GcTriggers;

// classes

class Alias;
class ArrayType;
class Attribute;
class AttributeBlock;
class BaseTypeSlot;
class ClassPtrType;
class ClassType;
class Const;
class DataPtrType;
class DerivableType;
class DynamicLayout;
class DynamicLib;
class DynamicSection;
class DynamicSectionGroup;
class EnumConst;
class EnumType;
class Field;
class Function;
class FunctionArg;
class FunctionOverload;
class FunctionPtrType;
class FunctionType;
class GlobalNamespace;
class MemberBlock;
class Module;
class ModuleItem;
class ModuleItemDecl;
class ModuleItemInitializer;
class NamedType;
class Namespace;
class Promise;
class Promisifier;
class Property;
class PropertyPtrType;
class PropertyType;
class Regex;
class RegexCapture;
class RegexMatch;
class RegexState;
class Scheduler;
class StructType;
class Type;
class Typedef;
class UnionType;
class Unit;
class Variable;

// properties

jnc.GcTriggers property g_gcTriggers;

// global functions

void* createDataPtr(
    void thin* p,
    size_t length = -1
);

void const* createDataPtr(
    void const thin* p,
    size_t length = -1
);

void* limitDataPtr(
    void* p,
    size_t length
);

void const* limitDataPtr(
    void const* p,
    size_t length
);

intptr_t getDataPtrLeftRadius(void const* p);
intptr_t getDataPtrRightRadius(void const* p);
jnc.GcStats getGcStats();
void collectGarbage();

} // namespace jnc