[Zope-CVS] CVS: PythonNet/src/runtime - ClassBase.cs:1.3 MetaType.cs:1.2 TypeGenerator.cs:NONE
Brian Lloyd
brian@zope.com
Wed, 30 Jul 2003 10:04:47 -0400
Update of /cvs-repository/PythonNet/src/runtime
In directory cvs.zope.org:/tmp/cvs-serv28625
Modified Files:
ClassBase.cs MetaType.cs
Removed Files:
TypeGenerator.cs
Log Message:
Minor fixups
=== PythonNet/src/runtime/ClassBase.cs 1.2 => 1.3 ===
--- PythonNet/src/runtime/ClassBase.cs:1.2 Thu Jul 24 19:55:00 2003
+++ PythonNet/src/runtime/ClassBase.cs Wed Jul 30 10:04:33 2003
@@ -69,11 +69,27 @@
[CallConvCdecl()]
public static void tp_dealloc(IntPtr ob) {
+ //DebugUtil.Print("tp_dealloc: ", ob);
+
ManagedType self = GetManagedObject(ob);
- //Console.WriteLine("dealloc: {0}", self.GetType());
Runtime.PyMem_Free(self.pyHandle);
Runtime.Decref(self.tpHandle);
self.gcHandle.Free();
+
+ //Console.WriteLine("tp_dealloc done");
+ }
+
+
+ [CallConvCdecl()]
+ public static int tp_traverse(IntPtr ob, IntPtr func, IntPtr args) {
+ DebugUtil.Print("tp_traverse: ", ob);
+ return 0;
+ }
+
+ [CallConvCdecl()]
+ public static int tp_clear(IntPtr ob) {
+ DebugUtil.Print("tp_clear: ", ob);
+ return 0;
}
=== PythonNet/src/runtime/MetaType.cs 1.1 => 1.2 ===
--- PythonNet/src/runtime/MetaType.cs:1.1 Mon Jul 14 15:59:51 2003
+++ PythonNet/src/runtime/MetaType.cs Wed Jul 30 10:04:33 2003
@@ -221,7 +221,7 @@
// single inheritance and don't interoperate with other types.
PyTypeObject sub = new PyTypeObject();
- string tp_name = Runtime.PyString_AsString(name);
+ string tp_name = Runtime.GetManagedString(name);
sub.tp_name = Marshal.StringToHGlobalAnsi(tp_name);
sub.ob_type = PyCLRMetaType;
sub.ob_refcnt = (IntPtr) 1;
=== Removed File PythonNet/src/runtime/TypeGenerator.cs ===