Artifacts Associated With Ticket 1791190
Ticket change [9170694014] (rid 120614) by dkf on 2007-09-09 19:19:44:
- assignee initialized to: "dkf"
- cmimetype initialized to: "text/plain"
- comment initialized to:
[20:15]apwdkf_, as the first implementation round of itcl is done, I would like to come back to the public C-API interfaces I would like to have. I have pasted them here for discussion with you: http://paste.tclers.tk/379
- foundin initialized to: "None"
- is_private initialized to: "0"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "dkf"
- subsystem initialized to: "None"
- title initialized to: "TclOO: extra interfaces for apw"
- type initialized to: "Patch"
Add attachment "extra.c" [6963a280fc] (rid 103241) by dkf on 2007-09-10 02:19:44.
Ticket change [74c1e432db] (rid 105263) by dkf on 2007-09-10 02:19:44:
- icomment:
File Added - 244854: extra.c
- login: "dkf"
- mimetype: "text/plain"
- username: "dkf"
- icomment:
Ticket change [863d354639] (rid 131465) by dkf on 2007-10-02 05:18:26:
- subsystem changed to: "35. TclOO Package"
Ticket change [fb4db1db42] (rid 92035) by dkf on 2007-12-30 22:35:15:
- icomment:
Logged In: YES user_id=79902 Originator: YES Tcl_Method Tcl_NewProcMethod( Tcl_Interp *interp, /* The interpreter containing the object. */ Tcl_Object oPtr, /* The object to modify. */ TclOO_PreCallProc preCallPtr, TclOO_PostCallProc postCallPtr, Tcl_ProcErrorProc errProc, ClientData clientData, Tcl_Obj *nameObj, /* The name of the method, which must not be * NULL. */ Tcl_Obj *argsObj, /* The formal argument list for the method, * which must not be NULL. */ Tcl_Obj *bodyObj, /* The body of the method, which must not be * NULL. */ int flags, /* Whether this is a public method. */ ClientData *clientData2) { ProcedureMethod *pmPtr; Tcl_Method method; method = (Tcl_Method)TclOONewProcMethod(interp, (Object *)oPtr, flags, nameObj, argsObj, bodyObj, &pmPtr); pmPtr->flags = flags & USE_DECLARER_NS; pmPtr->preCallProc = preCallPtr; pmPtr->postCallProc = postCallPtr; pmPtr->errProc = errProc; pmPtr->clientData = clientData; if (clientData2 != NULL) { *clientData2 = pmPtr; } return method; } Tcl_Method Tcl_NewProcClassMethod( Tcl_Interp *interp, /* The interpreter containing the class. */ Tcl_Class clsPtr, /* The class to modify. */ TclOO_PreCallProc preCallPtr, TclOO_PostCallProc postCallPtr, Tcl_ProcErrorProc errProc, ClientData clientData, Tcl_Obj *nameObj, /* The name of the method, which may be NULL; * if so, up to caller to manage storage * (e.g., because it is a constructor or * destructor). */ Tcl_Obj *argsObj, /* The formal argument list for the method, * which may be NULL; if so, it is equivalent * to an empty list. */ Tcl_Obj *bodyObj, /* The body of the method, which must not be * NULL. */ int flags, /* Whether this is a public method. */ ClientData *clientData2) { ProcedureMethod *pmPtr; Method *method; method = TclOONewProcClassMethod(interp, (Class *)clsPtr, flags, nameObj, argsObj, bodyObj, &pmPtr); pmPtr->flags = flags & USE_DECLARER_NS; pmPtr->preCallProc = preCallPtr; pmPtr->postCallProc = postCallPtr; pmPtr->errProc = errProc; pmPtr->clientData = clientData; if (clientData2 != NULL) { *clientData2 = pmPtr; } return (Tcl_Method)method; } #define PUBLIC_METHOD 0x01 /* This is a public (exported) method. */ #define PRIVATE_METHOD 0x02 /* This is a private (class's direct instances * only) method. */ #define USE_DECLARER_NS 0x80 /* * ---------------------------------------------------------------------- * * Tcl_PublicObjectCmd, Tcl_PrivateObjectCmd -- * * ---------------------------------------------------------------------- */ int Tcl_PublicObjectCmd( ClientData clientData, Tcl_Interp *interp, Tcl_Class clsPtr, int objc, Tcl_Obj *const *objv) { Object *oPtr = (Object *)clientData; int result; result = TclOOObjectCmdCore(oPtr, interp, objc, objv, PUBLIC_METHOD, &oPtr->publicContextCache, (Class *)clsPtr); return result; } int Tcl_PrivateObjectCmd( ClientData clientData, Tcl_Interp *interp, Tcl_Class clsPtr, int objc, Tcl_Obj *const *objv) { Object *oPtr = (Object *)clientData; int result; result = TclOOObjectCmdCore(oPtr, interp, objc, objv, PRIVATE_METHOD, &oPtr->publicContextCache, (Class *)clsPtr); return result; } - login: "dkf"
- mimetype: "text/plain"
- username: "dkf"
- icomment:
Ticket change [35ed8516d0] (rid 107028) by dkf on 2007-12-30 22:35:43:
- priority changed to: "6"
Ticket change [8c81708917] (rid 127752) by dkf on 2008-01-06 05:56:47:
- closedate changed to: "2008-01-05T22:56:47"
- closer changed to: "dkf"
- icomment:
Logged In: YES user_id=79902 Originator: YES Accepted as three functions: TclOOInvokeObject in tclOO.c (approx Tcl_PublicObjectCmd and Tcl_PrivateObjectCmd rolled into one, with fewer type hazards) TclOONewProcClassMethodEx and TclOONewProcInstanceMethodEx in tclOOMethod.c (Tcl_NewProcClassMethod and Tcl_NewProcMethod respectively with minor type signature changes for sanity) All functions are in the private interface for now since they expose concepts (especially a "start class") and types (some of those callbacks) that are not public.
- login: "dkf"
- mimetype: "text/plain"
- resolution changed to: "Accepted"
- status changed to: "Closed"
- username: "dkf"