Browse Source

Added an Std.Map wrapper to be able to use it in internal declarations.

pull/219/head
triton 12 years ago
parent
commit
df58e2774f
  1. 3
      src/Generator/Types/Std/Stdlib.cs
  2. 11
      src/Runtime/StdMap.cs

3
src/Generator/Types/Std/Stdlib.cs

@ -231,6 +231,9 @@ namespace CppSharp.Types.Std @@ -231,6 +231,9 @@ namespace CppSharp.Types.Std
public override string CSharpSignature(CSharpTypePrinterContext ctx)
{
if (ctx.CSharpKind == CSharpTypePrinterContextKind.Native)
return "Std.Map";
var type = Type as TemplateSpecializationType;
return string.Format("System.Collections.Generic.Dictionary<{0}, {1}>",
type.Arguments[0].Type, type.Arguments[1].Type);

11
src/Runtime/StdMap.cs

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
using System;
using System.Runtime.InteropServices;
namespace Std
{
[StructLayout(LayoutKind.Sequential)]
public unsafe struct Map
{
}
}
Loading…
Cancel
Save