public TypeSyntax PortType(CXType type) { if (type.kind == CXTypeKind.CXType_Pointer) return CommonTypes.IntPtrTypeSyntax; if (type.kind == CXTypeKind.CXType_ObjCObjectPointer) { type = type.GetPointee (); return SF.ParseTypeName (type.ToString ()); } if (type.kind == CXTypeKind.CXType_Void) return CommonTypes.VoidTypeSyntax; if (type.kind == CXTypeKind.CXType_Int) return CommonTypes.IntTypeSyntax; if (type.kind == CXTypeKind.CXType_Float) return CommonTypes.FloatTypeSyntax; if (type.kind == CXTypeKind.CXType_Double) return CommonTypes.DoubleTypeSyntax; return SF.ParseTypeName (Prettify (type)); }