CppInterOp
C++ Language Interoperability Layer
Loading...
Searching...
No Matches
CXCppInterOpGenerated.cpp
Go to the documentation of this file.
1// Auto-generated C API forwarding implementations.
2// Each function calls the corresponding Cpp:: C++ API.
3
5
6#include <cstdlib>
7#include <cstring>
8
9// The generated Impl.inc uses the prefixed C-side names (CppDeclRef etc.)
10// in extern "C" signatures. Alias them to the namespaced Cpp::* types so
11// the wrapper compiles; layout-identical, no conversion at call sites.
12using CppDeclRef = Cpp::DeclRef;
13using CppTypeRef = Cpp::TypeRef;
14using CppFuncRef = Cpp::FuncRef;
15using CppObjectRef = Cpp::ObjectRef;
16using CppInterpRef = Cpp::InterpRef;
17using CppConstDeclRef = Cpp::ConstDeclRef;
18using CppConstTypeRef = Cpp::ConstTypeRef;
19using CppConstFuncRef = Cpp::ConstFuncRef;
20// Unprefixed bare names — the emitter constructs std::vector<DeclRef>
21// etc. as out-param scratch buffers inside wrapper bodies.
22using Cpp::ConstDeclRef;
23using Cpp::ConstFuncRef;
24using Cpp::ConstTypeRef;
25using Cpp::DeclRef;
26using Cpp::FuncRef;
27using Cpp::InterpRef;
28using Cpp::ObjectRef;
29using Cpp::TypeRef;
30
31extern "C" {
32#include "CppInterOp/CXCppInterOpImpl.inc"
33}
Opaque handle types for the CppInterOp C and C++ API.