Browse Source

Handle native to managed marshaling of pointers to primitive types.

pull/1/head
triton 13 years ago
parent
commit
8f02c6a2dd
  1. 6
      src/Generator/Generators/CLI/CLIMarshal.cs

6
src/Generator/Generators/CLI/CLIMarshal.cs

@ -55,6 +55,10 @@ namespace Cxxi.Generators.CLI @@ -55,6 +55,10 @@ namespace Cxxi.Generators.CLI
return true;
}
PrimitiveType primitive;
if (pointee.IsPrimitiveType(out primitive, walkTypedefs: true))
Return += "*";
if (!pointee.Visit(this, quals))
return false;
@ -89,7 +93,7 @@ namespace Cxxi.Generators.CLI @@ -89,7 +93,7 @@ namespace Cxxi.Generators.CLI
case PrimitiveType.UInt64:
case PrimitiveType.Float:
case PrimitiveType.Double:
Return = Context.ReturnVarName;
Return += Context.ReturnVarName;
return true;
case PrimitiveType.WideChar:
return false;

Loading…
Cancel
Save