mirror of https://github.com/mono/CppSharp.git
39 changed files with 7205 additions and 34 deletions
@ -0,0 +1,29 @@ |
|||||||
|
#include <AST.h> |
||||||
|
#include <Sources.h> |
||||||
|
#include <CppParser.h> |
||||||
|
|
||||||
|
template class vector<CppSharp::CppParser::AST::Namespace*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Function*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Class*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Template*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypedefDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypeAlias*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Variable*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Friend*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BaseClassSpecifier*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Field*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Method*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::AccessSpecifierDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Declaration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::FunctionTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Parameter*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::ClassTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration::Item*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BlockContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::PreprocessedEntity*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Expression*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::MacroDefinition*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TranslationUnit*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::InlineContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::VerbatimBlockLineComment*>; |
@ -0,0 +1,4 @@ |
|||||||
|
#include <string> |
||||||
|
|
||||||
|
template class __declspec(dllexport) std::allocator<char>; |
||||||
|
template class __declspec(dllexport) std::basic_string<char, std::char_traits<char>, std::allocator<char>>; |
@ -0,0 +1,701 @@ |
|||||||
|
//----------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// This is autogenerated code by CppSharp.
|
||||||
|
// Do not edit this file or all your changes will be lost after re-generation.
|
||||||
|
// </auto-generated>
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
using System; |
||||||
|
using System.Runtime.InteropServices; |
||||||
|
using System.Security; |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
namespace __1 |
||||||
|
{ |
||||||
|
public unsafe partial class allocator : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSt3__19allocatorIcEC2Ev")] |
||||||
|
internal static extern void ctor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static allocator __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static allocator __CreateInstance(allocator.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(allocator.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(0); |
||||||
|
*(allocator.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private allocator(allocator.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected allocator(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public allocator() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(0); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
Internal.ctor_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __destruct_n |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 4)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public uint size; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class bad_weak_ptr |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 4)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr vptr_exception; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe abstract partial class __shared_count |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 8)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr vptr___shared_count; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public int __shared_owners_; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe abstract partial class __shared_weak_count |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr vptr___shared_count; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public int __shared_owners_; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public int __shared_weak_owners_; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __sp_mut |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 4)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr __lx; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class pointer_safety |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 4)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace __pointer_type_imp |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
namespace __1 |
||||||
|
{ |
||||||
|
public unsafe partial class basic_string : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public uint __cap_; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public uint __size_; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public global::System.IntPtr __data_; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public byte __size_1; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public sbyte __lx; |
||||||
|
|
||||||
|
[FieldOffset(1)] |
||||||
|
public fixed sbyte __data_1[11]; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy___data_1_1; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy___data_1_2; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy___data_1_3; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy___data_1_4; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy___data_1_5; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy___data_1_6; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy___data_1_7; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy___data_1_8; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy___data_1_9; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy___data_1_10; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed uint __words[3]; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public uint __dummy___words_1; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public uint __dummy___words_2; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNKSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE5c_strEv")] |
||||||
|
internal static extern global::System.IntPtr c_str_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
internal enum short_mask : uint |
||||||
|
{ |
||||||
|
__short_mask = 0x1 |
||||||
|
} |
||||||
|
|
||||||
|
internal enum long_mask : uint |
||||||
|
{ |
||||||
|
__long_mask = 0x1 |
||||||
|
} |
||||||
|
|
||||||
|
internal enum min_cap : uint |
||||||
|
{ |
||||||
|
__min_cap = 11 |
||||||
|
} |
||||||
|
|
||||||
|
internal enum n_words : uint |
||||||
|
{ |
||||||
|
__n_words = 3 |
||||||
|
} |
||||||
|
|
||||||
|
[Flags] |
||||||
|
internal enum alignment : uint |
||||||
|
{ |
||||||
|
__alignment = 16 |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __rep : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial struct _ |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __rep> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __rep>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __rep __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __rep(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __rep __CreateInstance(__rep.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __rep(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__rep.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(12); |
||||||
|
*(__rep.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __rep(__rep.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __rep(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __rep() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(12); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__rep __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __long : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public uint __cap_; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public uint __size_; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public global::System.IntPtr __data_; |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __long> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __long>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __long __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __long(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __long __CreateInstance(__long.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __long(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__long.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(12); |
||||||
|
*(__long.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __long(__long.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __long(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __long() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(12); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__long __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __short : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(1)] |
||||||
|
public fixed sbyte __data_[11]; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy___data__1; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy___data__2; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy___data__3; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy___data__4; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy___data__5; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy___data__6; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy___data__7; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy___data__8; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy___data__9; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy___data__10; |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial struct _ |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 1)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public byte __size_; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public sbyte __lx; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __short> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __short>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __short __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __short(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __short __CreateInstance(__short.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __short(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__short.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(12); |
||||||
|
*(__short.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __short(__short.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __short(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __short() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(12); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__short __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __raw : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed uint __words[3]; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public uint __dummy___words_1; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public uint __dummy___words_2; |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __raw> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __raw>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __raw __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __raw(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __raw __CreateInstance(__raw.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __raw(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__raw.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(12); |
||||||
|
*(__raw.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __raw(__raw.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __raw(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __raw() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(12); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__raw __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial struct __ulx |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 12)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
|
||||||
|
private __ulx.Internal __instance; |
||||||
|
public __ulx.Internal __Instance { get { return __instance; } } |
||||||
|
|
||||||
|
public static __ulx __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __ulx(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __ulx __CreateInstance(__ulx.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __ulx(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private __ulx(__ulx.Internal native, bool skipVTables = false) |
||||||
|
: this() |
||||||
|
{ |
||||||
|
__instance = native; |
||||||
|
} |
||||||
|
|
||||||
|
private __ulx(void* native, bool skipVTables = false) : this() |
||||||
|
{ |
||||||
|
__instance = *(Internal*) native; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(basic_string.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(basic_string.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(12); |
||||||
|
*(basic_string.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private basic_string(basic_string.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected basic_string(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public string c_str() |
||||||
|
{ |
||||||
|
var __ret = Internal.c_str_0((__Instance + __PointerAdjustment)); |
||||||
|
return Marshal.PtrToStringAnsi(__ret); |
||||||
|
} |
||||||
|
|
||||||
|
public static uint npos |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (uint*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE4nposE"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,30 @@ |
|||||||
|
#include <AST.h> |
||||||
|
#include <Sources.h> |
||||||
|
#include <CppParser.h> |
||||||
|
|
||||||
|
template class vector<CppSharp::CppParser::AST::Namespace*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Function*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Class*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Template*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypedefDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypeAlias*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Variable*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Friend*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BaseClassSpecifier*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Field*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Method*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::AccessSpecifierDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Declaration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::FunctionTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Parameter*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration::Item*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BlockContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::PreprocessedEntity*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Expression*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::ClassTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::VarTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::MacroDefinition*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TranslationUnit*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::InlineContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::VerbatimBlockLineComment*>; |
@ -0,0 +1,4 @@ |
|||||||
|
#include <string> |
||||||
|
|
||||||
|
template class __declspec(dllexport) std::allocator<char>; |
||||||
|
template class __declspec(dllexport) std::basic_string<char, std::char_traits<char>, std::allocator<char>>; |
@ -0,0 +1,317 @@ |
|||||||
|
//----------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// This is autogenerated code by CppSharp.
|
||||||
|
// Do not edit this file or all your changes will be lost after re-generation.
|
||||||
|
// </auto-generated>
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
using System; |
||||||
|
using System.Runtime.InteropServices; |
||||||
|
using System.Security; |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
public unsafe partial class allocator : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.ThisCall, |
||||||
|
EntryPoint="??0?$allocator@D@std@@QAE@XZ")] |
||||||
|
internal static extern global::System.IntPtr ctor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static allocator __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static allocator __CreateInstance(allocator.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(allocator.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(0); |
||||||
|
*(allocator.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private allocator(allocator.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected allocator(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public allocator() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(0); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
Internal.ctor_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_allocate |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_construct |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_destroy |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_max_size |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_select |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
public unsafe partial class basic_string : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed sbyte _Buf[16]; |
||||||
|
|
||||||
|
[FieldOffset(1)] |
||||||
|
public sbyte __dummy__Buf_1; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy__Buf_2; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy__Buf_3; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy__Buf_4; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy__Buf_5; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy__Buf_6; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy__Buf_7; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy__Buf_8; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy__Buf_9; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy__Buf_10; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy__Buf_11; |
||||||
|
|
||||||
|
[FieldOffset(12)] |
||||||
|
public sbyte __dummy__Buf_12; |
||||||
|
|
||||||
|
[FieldOffset(13)] |
||||||
|
public sbyte __dummy__Buf_13; |
||||||
|
|
||||||
|
[FieldOffset(14)] |
||||||
|
public sbyte __dummy__Buf_14; |
||||||
|
|
||||||
|
[FieldOffset(15)] |
||||||
|
public sbyte __dummy__Buf_15; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr _Ptr; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed sbyte _Alias[16]; |
||||||
|
|
||||||
|
[FieldOffset(1)] |
||||||
|
public sbyte __dummy__Alias_1; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy__Alias_2; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy__Alias_3; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy__Alias_4; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy__Alias_5; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy__Alias_6; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy__Alias_7; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy__Alias_8; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy__Alias_9; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy__Alias_10; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy__Alias_11; |
||||||
|
|
||||||
|
[FieldOffset(12)] |
||||||
|
public sbyte __dummy__Alias_12; |
||||||
|
|
||||||
|
[FieldOffset(13)] |
||||||
|
public sbyte __dummy__Alias_13; |
||||||
|
|
||||||
|
[FieldOffset(14)] |
||||||
|
public sbyte __dummy__Alias_14; |
||||||
|
|
||||||
|
[FieldOffset(15)] |
||||||
|
public sbyte __dummy__Alias_15; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public uint _Mysize; |
||||||
|
|
||||||
|
[FieldOffset(20)] |
||||||
|
public uint _Myres; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.ThisCall, |
||||||
|
EntryPoint="??1?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@XZ")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance, int delete); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.ThisCall, |
||||||
|
EntryPoint="?c_str@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEPBDXZ")] |
||||||
|
internal static extern global::System.IntPtr c_str_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(basic_string.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(basic_string.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(basic_string.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private basic_string(basic_string.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected basic_string(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.basic_string __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment), 0); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public string c_str() |
||||||
|
{ |
||||||
|
var __ret = Internal.c_str_0((__Instance + __PointerAdjustment)); |
||||||
|
return Marshal.PtrToStringAnsi(__ret); |
||||||
|
} |
||||||
|
|
||||||
|
public static uint npos |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (uint*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "?npos@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@2IB"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,29 @@ |
|||||||
|
#include <AST.h> |
||||||
|
#include <Sources.h> |
||||||
|
#include <CppParser.h> |
||||||
|
|
||||||
|
template class vector<CppSharp::CppParser::AST::Namespace*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Function*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Class*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Template*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypedefDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypeAlias*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Variable*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Friend*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BaseClassSpecifier*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Field*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Method*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::AccessSpecifierDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Declaration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::FunctionTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Parameter*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::ClassTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration::Item*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BlockContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::PreprocessedEntity*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Expression*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::MacroDefinition*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TranslationUnit*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::InlineContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::VerbatimBlockLineComment*>; |
@ -0,0 +1,4 @@ |
|||||||
|
#include <string> |
||||||
|
|
||||||
|
template class __declspec(dllexport) std::allocator<char>; |
||||||
|
template class __declspec(dllexport) std::basic_string<char, std::char_traits<char>, std::allocator<char>>; |
@ -0,0 +1,773 @@ |
|||||||
|
//----------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// This is autogenerated code by CppSharp.
|
||||||
|
// Do not edit this file or all your changes will be lost after re-generation.
|
||||||
|
// </auto-generated>
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
using System; |
||||||
|
using System.Runtime.InteropServices; |
||||||
|
using System.Security; |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
namespace __1 |
||||||
|
{ |
||||||
|
public unsafe partial class allocator : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSt3__19allocatorIcEC2Ev")] |
||||||
|
internal static extern void ctor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static allocator __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static allocator __CreateInstance(allocator.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(allocator.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(0); |
||||||
|
*(allocator.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private allocator(allocator.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected allocator(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public allocator() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(0); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
Internal.ctor_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __destruct_n |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 8)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public ulong size; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class bad_weak_ptr |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 8)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr vptr_exception; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe abstract partial class __shared_count |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 16)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr vptr___shared_count; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public long __shared_owners_; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe abstract partial class __shared_weak_count |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr vptr___shared_count; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public long __shared_owners_; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public long __shared_weak_owners_; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __sp_mut |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 8)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr __lx; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class pointer_safety |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 4)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace __pointer_type_imp |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
namespace __1 |
||||||
|
{ |
||||||
|
public unsafe partial class basic_string : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public ulong __cap_; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public ulong __size_; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public global::System.IntPtr __data_; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public byte __size_1; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public sbyte __lx; |
||||||
|
|
||||||
|
[FieldOffset(1)] |
||||||
|
public fixed sbyte __data_1[23]; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy___data_1_1; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy___data_1_2; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy___data_1_3; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy___data_1_4; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy___data_1_5; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy___data_1_6; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy___data_1_7; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy___data_1_8; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy___data_1_9; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy___data_1_10; |
||||||
|
|
||||||
|
[FieldOffset(12)] |
||||||
|
public sbyte __dummy___data_1_11; |
||||||
|
|
||||||
|
[FieldOffset(13)] |
||||||
|
public sbyte __dummy___data_1_12; |
||||||
|
|
||||||
|
[FieldOffset(14)] |
||||||
|
public sbyte __dummy___data_1_13; |
||||||
|
|
||||||
|
[FieldOffset(15)] |
||||||
|
public sbyte __dummy___data_1_14; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public sbyte __dummy___data_1_15; |
||||||
|
|
||||||
|
[FieldOffset(17)] |
||||||
|
public sbyte __dummy___data_1_16; |
||||||
|
|
||||||
|
[FieldOffset(18)] |
||||||
|
public sbyte __dummy___data_1_17; |
||||||
|
|
||||||
|
[FieldOffset(19)] |
||||||
|
public sbyte __dummy___data_1_18; |
||||||
|
|
||||||
|
[FieldOffset(20)] |
||||||
|
public sbyte __dummy___data_1_19; |
||||||
|
|
||||||
|
[FieldOffset(21)] |
||||||
|
public sbyte __dummy___data_1_20; |
||||||
|
|
||||||
|
[FieldOffset(22)] |
||||||
|
public sbyte __dummy___data_1_21; |
||||||
|
|
||||||
|
[FieldOffset(23)] |
||||||
|
public sbyte __dummy___data_1_22; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed ulong __words[3]; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public ulong __dummy___words_1; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public ulong __dummy___words_2; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNKSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE5c_strEv")] |
||||||
|
internal static extern global::System.IntPtr c_str_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
internal enum short_mask : uint |
||||||
|
{ |
||||||
|
__short_mask = 0x1 |
||||||
|
} |
||||||
|
|
||||||
|
internal enum long_mask : uint |
||||||
|
{ |
||||||
|
__long_mask = 0x1 |
||||||
|
} |
||||||
|
|
||||||
|
internal enum min_cap : uint |
||||||
|
{ |
||||||
|
__min_cap = 23 |
||||||
|
} |
||||||
|
|
||||||
|
internal enum n_words : uint |
||||||
|
{ |
||||||
|
__n_words = 3 |
||||||
|
} |
||||||
|
|
||||||
|
[Flags] |
||||||
|
internal enum alignment : uint |
||||||
|
{ |
||||||
|
__alignment = 16 |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __rep : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial struct _ |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __rep> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __rep>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __rep __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __rep(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __rep __CreateInstance(__rep.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __rep(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__rep.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(__rep.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __rep(__rep.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __rep(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __rep() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(24); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__rep __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __long : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public ulong __cap_; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public ulong __size_; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public global::System.IntPtr __data_; |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __long> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __long>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __long __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __long(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __long __CreateInstance(__long.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __long(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__long.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(__long.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __long(__long.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __long(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __long() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(24); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__long __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __short : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(1)] |
||||||
|
public fixed sbyte __data_[23]; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy___data__1; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy___data__2; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy___data__3; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy___data__4; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy___data__5; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy___data__6; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy___data__7; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy___data__8; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy___data__9; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy___data__10; |
||||||
|
|
||||||
|
[FieldOffset(12)] |
||||||
|
public sbyte __dummy___data__11; |
||||||
|
|
||||||
|
[FieldOffset(13)] |
||||||
|
public sbyte __dummy___data__12; |
||||||
|
|
||||||
|
[FieldOffset(14)] |
||||||
|
public sbyte __dummy___data__13; |
||||||
|
|
||||||
|
[FieldOffset(15)] |
||||||
|
public sbyte __dummy___data__14; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public sbyte __dummy___data__15; |
||||||
|
|
||||||
|
[FieldOffset(17)] |
||||||
|
public sbyte __dummy___data__16; |
||||||
|
|
||||||
|
[FieldOffset(18)] |
||||||
|
public sbyte __dummy___data__17; |
||||||
|
|
||||||
|
[FieldOffset(19)] |
||||||
|
public sbyte __dummy___data__18; |
||||||
|
|
||||||
|
[FieldOffset(20)] |
||||||
|
public sbyte __dummy___data__19; |
||||||
|
|
||||||
|
[FieldOffset(21)] |
||||||
|
public sbyte __dummy___data__20; |
||||||
|
|
||||||
|
[FieldOffset(22)] |
||||||
|
public sbyte __dummy___data__21; |
||||||
|
|
||||||
|
[FieldOffset(23)] |
||||||
|
public sbyte __dummy___data__22; |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial struct _ |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 1)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public byte __size_; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public sbyte __lx; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __short> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __short>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __short __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __short(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __short __CreateInstance(__short.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __short(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__short.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(__short.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __short(__short.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __short(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __short() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(24); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__short __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class __raw : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed ulong __words[3]; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public ulong __dummy___words_1; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public ulong __dummy___words_2; |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __raw> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, __raw>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static __raw __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __raw(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __raw __CreateInstance(__raw.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __raw(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(__raw.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(__raw.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private __raw(__raw.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected __raw(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public __raw() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(24); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string.__raw __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial struct __ulx |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
|
||||||
|
private __ulx.Internal __instance; |
||||||
|
public __ulx.Internal __Instance { get { return __instance; } } |
||||||
|
|
||||||
|
public static __ulx __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __ulx(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static __ulx __CreateInstance(__ulx.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new __ulx(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private __ulx(__ulx.Internal native, bool skipVTables = false) |
||||||
|
: this() |
||||||
|
{ |
||||||
|
__instance = native; |
||||||
|
} |
||||||
|
|
||||||
|
private __ulx(void* native, bool skipVTables = false) : this() |
||||||
|
{ |
||||||
|
__instance = *(Internal*) native; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(basic_string.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(basic_string.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(basic_string.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private basic_string(basic_string.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected basic_string(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__1.basic_string __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public string c_str() |
||||||
|
{ |
||||||
|
var __ret = Internal.c_str_0((__Instance + __PointerAdjustment)); |
||||||
|
return Marshal.PtrToStringAnsi(__ret); |
||||||
|
} |
||||||
|
|
||||||
|
public static ulong npos |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (ulong*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE4nposE"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,4 @@ |
|||||||
|
#include <string> |
||||||
|
|
||||||
|
template class __declspec(dllexport) std::basic_string<char, std::char_traits<char>, std::allocator<char>>; |
||||||
|
template class __declspec(dllexport) std::allocator<char>; |
@ -0,0 +1,358 @@ |
|||||||
|
//----------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// This is autogenerated code by CppSharp.
|
||||||
|
// Do not edit this file or all your changes will be lost after re-generation.
|
||||||
|
// </auto-generated>
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
using System; |
||||||
|
using System.Runtime.InteropServices; |
||||||
|
using System.Security; |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
public unsafe partial class allocator : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSaIcEC2Ev")] |
||||||
|
internal static extern void ctor_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSaIcED2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static allocator __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static allocator __CreateInstance(allocator.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(allocator.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(0); |
||||||
|
*(allocator.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private allocator(allocator.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected allocator(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public allocator() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(0); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
Internal.ctor_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
namespace __cxx11 |
||||||
|
{ |
||||||
|
public unsafe partial class basic_string : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 32)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr _M_p; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public ulong _M_string_length; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public fixed sbyte _M_local_buf[16]; |
||||||
|
|
||||||
|
[FieldOffset(17)] |
||||||
|
public sbyte __dummy__M_local_buf_1; |
||||||
|
|
||||||
|
[FieldOffset(18)] |
||||||
|
public sbyte __dummy__M_local_buf_2; |
||||||
|
|
||||||
|
[FieldOffset(19)] |
||||||
|
public sbyte __dummy__M_local_buf_3; |
||||||
|
|
||||||
|
[FieldOffset(20)] |
||||||
|
public sbyte __dummy__M_local_buf_4; |
||||||
|
|
||||||
|
[FieldOffset(21)] |
||||||
|
public sbyte __dummy__M_local_buf_5; |
||||||
|
|
||||||
|
[FieldOffset(22)] |
||||||
|
public sbyte __dummy__M_local_buf_6; |
||||||
|
|
||||||
|
[FieldOffset(23)] |
||||||
|
public sbyte __dummy__M_local_buf_7; |
||||||
|
|
||||||
|
[FieldOffset(24)] |
||||||
|
public sbyte __dummy__M_local_buf_8; |
||||||
|
|
||||||
|
[FieldOffset(25)] |
||||||
|
public sbyte __dummy__M_local_buf_9; |
||||||
|
|
||||||
|
[FieldOffset(26)] |
||||||
|
public sbyte __dummy__M_local_buf_10; |
||||||
|
|
||||||
|
[FieldOffset(27)] |
||||||
|
public sbyte __dummy__M_local_buf_11; |
||||||
|
|
||||||
|
[FieldOffset(28)] |
||||||
|
public sbyte __dummy__M_local_buf_12; |
||||||
|
|
||||||
|
[FieldOffset(29)] |
||||||
|
public sbyte __dummy__M_local_buf_13; |
||||||
|
|
||||||
|
[FieldOffset(30)] |
||||||
|
public sbyte __dummy__M_local_buf_14; |
||||||
|
|
||||||
|
[FieldOffset(31)] |
||||||
|
public sbyte __dummy__M_local_buf_15; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public ulong _M_allocated_capacity; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv")] |
||||||
|
internal static extern global::System.IntPtr c_str_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
internal enum S_local_capacity : uint |
||||||
|
{ |
||||||
|
_S_local_capacity = 15 |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_hider : global::std.allocator, IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 8)] |
||||||
|
public new partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr _M_p; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderD2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public static new _Alloc_hider __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Alloc_hider(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static _Alloc_hider __CreateInstance(_Alloc_hider.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Alloc_hider(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(_Alloc_hider.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(8); |
||||||
|
*(_Alloc_hider.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private _Alloc_hider(_Alloc_hider.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected _Alloc_hider(void* native, bool skipVTables = false) |
||||||
|
: base((void*) null) |
||||||
|
{ |
||||||
|
__PointerAdjustment = 0; |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
protected override void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial struct _ |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 16)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed sbyte _M_local_buf[16]; |
||||||
|
|
||||||
|
[FieldOffset(1)] |
||||||
|
public sbyte __dummy__M_local_buf_1; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy__M_local_buf_2; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy__M_local_buf_3; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy__M_local_buf_4; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy__M_local_buf_5; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy__M_local_buf_6; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy__M_local_buf_7; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy__M_local_buf_8; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy__M_local_buf_9; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy__M_local_buf_10; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy__M_local_buf_11; |
||||||
|
|
||||||
|
[FieldOffset(12)] |
||||||
|
public sbyte __dummy__M_local_buf_12; |
||||||
|
|
||||||
|
[FieldOffset(13)] |
||||||
|
public sbyte __dummy__M_local_buf_13; |
||||||
|
|
||||||
|
[FieldOffset(14)] |
||||||
|
public sbyte __dummy__M_local_buf_14; |
||||||
|
|
||||||
|
[FieldOffset(15)] |
||||||
|
public sbyte __dummy__M_local_buf_15; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public ulong _M_allocated_capacity; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(basic_string.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(basic_string.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(32); |
||||||
|
*(basic_string.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private basic_string(basic_string.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected basic_string(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.__cxx11.basic_string __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public string c_str() |
||||||
|
{ |
||||||
|
var __ret = Internal.c_str_0((__Instance + __PointerAdjustment)); |
||||||
|
return Marshal.PtrToStringAnsi(__ret); |
||||||
|
} |
||||||
|
|
||||||
|
public static ulong npos |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (ulong*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4nposE"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,29 @@ |
|||||||
|
#include <AST.h> |
||||||
|
#include <Sources.h> |
||||||
|
#include <CppParser.h> |
||||||
|
|
||||||
|
template class vector<CppSharp::CppParser::AST::Namespace*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Function*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Class*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Template*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypedefDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypeAlias*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Variable*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Friend*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BaseClassSpecifier*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Field*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Method*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::AccessSpecifierDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Declaration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::FunctionTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Parameter*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::ClassTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration::Item*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BlockContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::PreprocessedEntity*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Expression*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::MacroDefinition*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TranslationUnit*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::InlineContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::VerbatimBlockLineComment*>; |
@ -0,0 +1,4 @@ |
|||||||
|
#include <string> |
||||||
|
|
||||||
|
template class __declspec(dllexport) std::basic_string<char, std::char_traits<char>, std::allocator<char>>; |
||||||
|
template class __declspec(dllexport) std::allocator<char>; |
@ -0,0 +1,505 @@ |
|||||||
|
//----------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// This is autogenerated code by CppSharp.
|
||||||
|
// Do not edit this file or all your changes will be lost after re-generation.
|
||||||
|
// </auto-generated>
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
using System; |
||||||
|
using System.Runtime.InteropServices; |
||||||
|
using System.Security; |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
public unsafe partial class allocator : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSaIcEC2Ev")] |
||||||
|
internal static extern void ctor_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSaIcED2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static allocator __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static allocator __CreateInstance(allocator.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(allocator.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(0); |
||||||
|
*(allocator.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private allocator(allocator.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected allocator(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public allocator() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(0); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
Internal.ctor_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
public unsafe partial class basic_string : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 8)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr _M_p; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSsD2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNKSs5c_strEv")] |
||||||
|
internal static extern global::System.IntPtr c_str_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_hider : global::std.allocator, IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 8)] |
||||||
|
public new partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr _M_p; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSs12_Alloc_hiderD2Ev")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public static new _Alloc_hider __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Alloc_hider(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static _Alloc_hider __CreateInstance(_Alloc_hider.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Alloc_hider(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(_Alloc_hider.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(8); |
||||||
|
*(_Alloc_hider.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private _Alloc_hider(_Alloc_hider.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected _Alloc_hider(void* native, bool skipVTables = false) |
||||||
|
: base((void*) null) |
||||||
|
{ |
||||||
|
__PointerAdjustment = 0; |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
protected override void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public sbyte* _M_p |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
return ((Internal*) __Instance)->_M_p; |
||||||
|
} |
||||||
|
|
||||||
|
set |
||||||
|
{ |
||||||
|
((Internal*) __Instance)->_M_p = (global::System.IntPtr) value; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Rep_base : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public ulong _M_length; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public ulong _M_capacity; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public int _M_refcount; |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, _Rep_base> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, _Rep_base>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static _Rep_base __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Rep_base(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static _Rep_base __CreateInstance(_Rep_base.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Rep_base(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(_Rep_base.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(_Rep_base.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private _Rep_base(_Rep_base.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected _Rep_base(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public _Rep_base() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(24); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.basic_string._Rep_base __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public int _M_refcount |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
return ((Internal*) __Instance)->_M_refcount; |
||||||
|
} |
||||||
|
|
||||||
|
set |
||||||
|
{ |
||||||
|
((Internal*) __Instance)->_M_refcount = value; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Rep : global::std.basic_string._Rep_base, IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 24)] |
||||||
|
public new partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public ulong _M_length; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public ulong _M_capacity; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public int _M_refcount; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSs4_Rep12_S_empty_repEv")] |
||||||
|
internal static extern global::System.IntPtr _S_empty_rep_0(); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNKSs4_Rep12_M_is_leakedEv")] |
||||||
|
[return: MarshalAsAttribute(UnmanagedType.I1)] |
||||||
|
internal static extern bool _M_is_leaked_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNKSs4_Rep12_M_is_sharedEv")] |
||||||
|
[return: MarshalAsAttribute(UnmanagedType.I1)] |
||||||
|
internal static extern bool _M_is_shared_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSs4_Rep13_M_set_leakedEv")] |
||||||
|
internal static extern void _M_set_leaked_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSs4_Rep15_M_set_sharableEv")] |
||||||
|
internal static extern void _M_set_sharable_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSs4_Rep10_M_refdataEv")] |
||||||
|
internal static extern sbyte* _M_refdata_0(global::System.IntPtr instance); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="_ZNSs4_Rep10_M_refcopyEv")] |
||||||
|
internal static extern sbyte* _M_refcopy_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public static new _Rep __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Rep(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static _Rep __CreateInstance(_Rep.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new _Rep(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(_Rep.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(24); |
||||||
|
*(_Rep.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private _Rep(_Rep.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected _Rep(void* native, bool skipVTables = false) |
||||||
|
: base((void*) null) |
||||||
|
{ |
||||||
|
__PointerAdjustment = 0; |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public _Rep() |
||||||
|
: this((void*) null) |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(24); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
public bool _M_is_leaked() |
||||||
|
{ |
||||||
|
var __ret = Internal._M_is_leaked_0((__Instance + __PointerAdjustment)); |
||||||
|
return __ret; |
||||||
|
} |
||||||
|
|
||||||
|
public bool _M_is_shared() |
||||||
|
{ |
||||||
|
var __ret = Internal._M_is_shared_0((__Instance + __PointerAdjustment)); |
||||||
|
return __ret; |
||||||
|
} |
||||||
|
|
||||||
|
public void _M_set_leaked() |
||||||
|
{ |
||||||
|
Internal._M_set_leaked_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public void _M_set_sharable() |
||||||
|
{ |
||||||
|
Internal._M_set_sharable_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public sbyte* _M_refdata() |
||||||
|
{ |
||||||
|
var __ret = Internal._M_refdata_0((__Instance + __PointerAdjustment)); |
||||||
|
return __ret; |
||||||
|
} |
||||||
|
|
||||||
|
public sbyte* _M_refcopy() |
||||||
|
{ |
||||||
|
var __ret = Internal._M_refcopy_0((__Instance + __PointerAdjustment)); |
||||||
|
return __ret; |
||||||
|
} |
||||||
|
|
||||||
|
public static global::std.basic_string._Rep _S_empty_rep() |
||||||
|
{ |
||||||
|
var __ret = Internal._S_empty_rep_0(); |
||||||
|
global::std.basic_string._Rep __result0; |
||||||
|
if (__ret == IntPtr.Zero) __result0 = null; |
||||||
|
else if (global::std.basic_string._Rep.NativeToManagedMap.ContainsKey(__ret)) |
||||||
|
__result0 = (global::std.basic_string._Rep) global::std.basic_string._Rep.NativeToManagedMap[__ret]; |
||||||
|
else __result0 = global::std.basic_string._Rep.__CreateInstance(__ret); |
||||||
|
return __result0; |
||||||
|
} |
||||||
|
|
||||||
|
public static ulong _S_max_size |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (ulong*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "_ZNSs4_Rep11_S_max_sizeE"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public static sbyte _S_terminal |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (sbyte*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "_ZNSs4_Rep11_S_terminalE"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public static ulong[] _S_empty_rep_storage |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (byte*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "_ZNSs4_Rep20_S_empty_rep_storageE"); |
||||||
|
return null; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(basic_string.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(basic_string.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(8); |
||||||
|
*(basic_string.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private basic_string(basic_string.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected basic_string(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.basic_string __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment)); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public string c_str() |
||||||
|
{ |
||||||
|
var __ret = Internal.c_str_0((__Instance + __PointerAdjustment)); |
||||||
|
return Marshal.PtrToStringAnsi(__ret); |
||||||
|
} |
||||||
|
|
||||||
|
public static ulong npos |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (ulong*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "_ZNSs4nposE"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,29 @@ |
|||||||
|
#include <AST.h> |
||||||
|
#include <Sources.h> |
||||||
|
#include <CppParser.h> |
||||||
|
|
||||||
|
template class vector<CppSharp::CppParser::AST::Namespace*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Function*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Class*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Template*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypedefDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TypeAlias*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Variable*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Friend*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BaseClassSpecifier*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Field*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Method*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::AccessSpecifierDecl*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Declaration*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::FunctionTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Parameter*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::ClassTemplateSpecialization*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Enumeration::Item*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::BlockContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::PreprocessedEntity*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::Expression*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::MacroDefinition*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::TranslationUnit*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::InlineContentComment*>; |
||||||
|
template class vector<CppSharp::CppParser::AST::VerbatimBlockLineComment*>; |
@ -0,0 +1,4 @@ |
|||||||
|
#include <string> |
||||||
|
|
||||||
|
template class __declspec(dllexport) std::allocator<char>; |
||||||
|
template class __declspec(dllexport) std::basic_string<char, std::char_traits<char>, std::allocator<char>>; |
@ -0,0 +1,317 @@ |
|||||||
|
//----------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// This is autogenerated code by CppSharp.
|
||||||
|
// Do not edit this file or all your changes will be lost after re-generation.
|
||||||
|
// </auto-generated>
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
using System; |
||||||
|
using System.Runtime.InteropServices; |
||||||
|
using System.Security; |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
public unsafe partial class allocator : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="??0?$allocator@D@std@@QEAA@XZ")] |
||||||
|
internal static extern global::System.IntPtr ctor_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, allocator>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static allocator __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static allocator __CreateInstance(allocator.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new allocator(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(allocator.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(0); |
||||||
|
*(allocator.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private allocator(allocator.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected allocator(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public allocator() |
||||||
|
{ |
||||||
|
__Instance = Marshal.AllocHGlobal(0); |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
Internal.ctor_0((__Instance + __PointerAdjustment)); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.allocator __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_allocate |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_construct |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_destroy |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_max_size |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public unsafe partial class _Alloc_select |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 0)] |
||||||
|
public partial struct Internal |
||||||
|
{ |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
namespace std |
||||||
|
{ |
||||||
|
public unsafe partial class basic_string : IDisposable |
||||||
|
{ |
||||||
|
[StructLayout(LayoutKind.Explicit, Size = 32)] |
||||||
|
public unsafe partial struct Internal |
||||||
|
{ |
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed sbyte _Buf[16]; |
||||||
|
|
||||||
|
[FieldOffset(1)] |
||||||
|
public sbyte __dummy__Buf_1; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy__Buf_2; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy__Buf_3; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy__Buf_4; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy__Buf_5; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy__Buf_6; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy__Buf_7; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy__Buf_8; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy__Buf_9; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy__Buf_10; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy__Buf_11; |
||||||
|
|
||||||
|
[FieldOffset(12)] |
||||||
|
public sbyte __dummy__Buf_12; |
||||||
|
|
||||||
|
[FieldOffset(13)] |
||||||
|
public sbyte __dummy__Buf_13; |
||||||
|
|
||||||
|
[FieldOffset(14)] |
||||||
|
public sbyte __dummy__Buf_14; |
||||||
|
|
||||||
|
[FieldOffset(15)] |
||||||
|
public sbyte __dummy__Buf_15; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public global::System.IntPtr _Ptr; |
||||||
|
|
||||||
|
[FieldOffset(0)] |
||||||
|
public fixed sbyte _Alias[16]; |
||||||
|
|
||||||
|
[FieldOffset(1)] |
||||||
|
public sbyte __dummy__Alias_1; |
||||||
|
|
||||||
|
[FieldOffset(2)] |
||||||
|
public sbyte __dummy__Alias_2; |
||||||
|
|
||||||
|
[FieldOffset(3)] |
||||||
|
public sbyte __dummy__Alias_3; |
||||||
|
|
||||||
|
[FieldOffset(4)] |
||||||
|
public sbyte __dummy__Alias_4; |
||||||
|
|
||||||
|
[FieldOffset(5)] |
||||||
|
public sbyte __dummy__Alias_5; |
||||||
|
|
||||||
|
[FieldOffset(6)] |
||||||
|
public sbyte __dummy__Alias_6; |
||||||
|
|
||||||
|
[FieldOffset(7)] |
||||||
|
public sbyte __dummy__Alias_7; |
||||||
|
|
||||||
|
[FieldOffset(8)] |
||||||
|
public sbyte __dummy__Alias_8; |
||||||
|
|
||||||
|
[FieldOffset(9)] |
||||||
|
public sbyte __dummy__Alias_9; |
||||||
|
|
||||||
|
[FieldOffset(10)] |
||||||
|
public sbyte __dummy__Alias_10; |
||||||
|
|
||||||
|
[FieldOffset(11)] |
||||||
|
public sbyte __dummy__Alias_11; |
||||||
|
|
||||||
|
[FieldOffset(12)] |
||||||
|
public sbyte __dummy__Alias_12; |
||||||
|
|
||||||
|
[FieldOffset(13)] |
||||||
|
public sbyte __dummy__Alias_13; |
||||||
|
|
||||||
|
[FieldOffset(14)] |
||||||
|
public sbyte __dummy__Alias_14; |
||||||
|
|
||||||
|
[FieldOffset(15)] |
||||||
|
public sbyte __dummy__Alias_15; |
||||||
|
|
||||||
|
[FieldOffset(16)] |
||||||
|
public ulong _Mysize; |
||||||
|
|
||||||
|
[FieldOffset(24)] |
||||||
|
public ulong _Myres; |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="??1?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@XZ")] |
||||||
|
internal static extern void dtor_0(global::System.IntPtr instance, int delete); |
||||||
|
|
||||||
|
[SuppressUnmanagedCodeSecurity] |
||||||
|
[DllImport("Std-templates", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, |
||||||
|
EntryPoint="?c_str@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBAPEBDXZ")] |
||||||
|
internal static extern global::System.IntPtr c_str_0(global::System.IntPtr instance); |
||||||
|
} |
||||||
|
|
||||||
|
public global::System.IntPtr __Instance { get; protected set; } |
||||||
|
|
||||||
|
protected int __PointerAdjustment; |
||||||
|
public static readonly System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string> NativeToManagedMap = new System.Collections.Concurrent.ConcurrentDictionary<IntPtr, basic_string>(); |
||||||
|
protected void*[] __OriginalVTables; |
||||||
|
|
||||||
|
protected bool __ownsNativeInstance; |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(global::System.IntPtr native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native.ToPointer(), skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
public static basic_string __CreateInstance(basic_string.Internal native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
return new basic_string(native, skipVTables); |
||||||
|
} |
||||||
|
|
||||||
|
private static void* __CopyValue(basic_string.Internal native) |
||||||
|
{ |
||||||
|
var ret = Marshal.AllocHGlobal(32); |
||||||
|
*(basic_string.Internal*) ret = native; |
||||||
|
return ret.ToPointer(); |
||||||
|
} |
||||||
|
|
||||||
|
private basic_string(basic_string.Internal native, bool skipVTables = false) |
||||||
|
: this(__CopyValue(native), skipVTables) |
||||||
|
{ |
||||||
|
__ownsNativeInstance = true; |
||||||
|
NativeToManagedMap[__Instance] = this; |
||||||
|
} |
||||||
|
|
||||||
|
protected basic_string(void* native, bool skipVTables = false) |
||||||
|
{ |
||||||
|
if (native == null) |
||||||
|
return; |
||||||
|
__Instance = new global::System.IntPtr(native); |
||||||
|
} |
||||||
|
|
||||||
|
public void Dispose() |
||||||
|
{ |
||||||
|
Dispose(disposing: true); |
||||||
|
} |
||||||
|
|
||||||
|
protected virtual void Dispose(bool disposing) |
||||||
|
{ |
||||||
|
global::std.basic_string __dummy; |
||||||
|
NativeToManagedMap.TryRemove(__Instance, out __dummy); |
||||||
|
Internal.dtor_0((__Instance + __PointerAdjustment), 0); |
||||||
|
if (__ownsNativeInstance) |
||||||
|
Marshal.FreeHGlobal(__Instance); |
||||||
|
} |
||||||
|
|
||||||
|
public string c_str() |
||||||
|
{ |
||||||
|
var __ret = Internal.c_str_0((__Instance + __PointerAdjustment)); |
||||||
|
return Marshal.PtrToStringAnsi(__ret); |
||||||
|
} |
||||||
|
|
||||||
|
public static ulong npos |
||||||
|
{ |
||||||
|
get |
||||||
|
{ |
||||||
|
var __ptr = (ulong*)CppSharp.SymbolResolver.ResolveSymbol("Std-templates", "?npos@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@2_KB"); |
||||||
|
return *__ptr; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
Loading…
Reference in new issue