Index: generic/nsf.c =================================================================== diff -u -r658c5ca127345b3f4377e551d5e9517c6481b473 -rbf951b5e794b88907333c62b9ebfdaf13c2f26dc --- generic/nsf.c (.../nsf.c) (revision 658c5ca127345b3f4377e551d5e9517c6481b473) +++ generic/nsf.c (.../nsf.c) (revision bf951b5e794b88907333c62b9ebfdaf13c2f26dc) @@ -5754,7 +5754,7 @@ } MEM_COUNT_ALLOC("NSNamespace", nsPtr); } else { - fprintf(stderr, "NSGetFreshNamespace: reusing namespace %p %s\n", nsPtr, nsPtr->fullName); + fprintf(stderr, "NSGetFreshNamespace: reusing namespace %p %s\n", (void *)nsPtr, nsPtr->fullName); } return (Tcl_Namespace *)nsPtr; @@ -6052,8 +6052,8 @@ #if !defined(NDEBUG) if (screenedObject != NULL) { NsfLog(interp, NSF_LOG_NOTICE, "screened object %s found: object %p (%s) cmd %p", - Tcl_GetCommandName(interp, cmdPtr), screenedObject, - ObjectName(screenedObject), cmdPtr); + Tcl_GetCommandName(interp, cmdPtr), (void *)screenedObject, + ObjectName(screenedObject), (void *)cmdPtr); } #endif return screenedObject; @@ -8340,8 +8340,8 @@ * Sanity check: it seems that we can create via * __default_superclass a class which has itself as subclass! */ - fprintf(stderr, "... STRANGE %p is subclass of %p %s, sub %p\n", sc->cl, - startCl, ClassName(startCl), startCl->sub); + fprintf(stderr, "... STRANGE %p is subclass of %p %s, sub %p\n", + (void *)sc->cl, (void *)startCl, ClassName(startCl), (void *)startCl->sub); continue; } #endif @@ -17015,8 +17015,8 @@ assert(prefix != NULL); assert(listObj != NULL); - /* fprintf(stderr, "AddSlotObjects parent %s prefix %s type %p %s\n", - ObjectName(parent), prefix, type, (type != NULL) ? ClassName(type) : "");*/ + /*fprintf(stderr, "AddSlotObjects parent %s prefix %s type %p %s\n", + ObjectName(parent), prefix, type, (type != NULL) ? ClassName(type) : "");*/ DSTRING_INIT(dsPtr); Tcl_DStringAppend(dsPtr, ObjectName(parent), -1); @@ -18627,7 +18627,7 @@ assert(mCl != NULL); /*fprintf(stderr, "DefaultSuperClass cl %s, mcl %s, isMeta %d\n", - ClassName(cl), ClassName(mcl), isMeta );*/ + ClassName(cl), ClassName(mCl), isMeta );*/ resultObj = Nsf_ObjGetVar2((Nsf_Object *)mCl, interp, (isMeta != 0) ? NsfGlobalObjs[NSF_DEFAULTMETACLASS] : @@ -18637,13 +18637,15 @@ if (unlikely(GetClassFromObj(interp, resultObj, &resultClass, 0) != TCL_OK)) { NsfPrintError(interp, "default superclass is not a class"); } - /* fprintf(stderr, "DefaultSuperClass for %s got from var %s\n", ClassName(cl), ObjStr(nameObj)); */ - + /*fprintf(stderr, "DefaultSuperClass for %s got from var %s => %s\n", + ClassName(cl), + ObjStr((isMeta != 0) ? NsfGlobalObjs[NSF_DEFAULTMETACLASS] : NsfGlobalObjs[NSF_DEFAULTSUPERCLASS]), + ClassName(resultClass));*/ } else { NsfClasses *sc; - /* fprintf(stderr, "DefaultSuperClass for %s: search in superClasses starting with %p meta %d\n", - ClassName(cl), cl->super, isMeta); */ + /*fprintf(stderr, "DefaultSuperClass for %s: search in superClasses starting with %p meta %d\n", + ClassName(cl), cl->super, isMeta);*/ if (isMeta != 0) { /* @@ -18789,7 +18791,7 @@ if (softrecreate == 0) { /* - * Reclass all instances of the current class the the appropriate + * Reclass all instances of the current class to the appropriate * most general class ("baseClass"). The most general class of a * metaclass is the root meta class, the most general class of an * object is the root class. Instances of meta-classes can be only @@ -23551,7 +23553,7 @@ NsfLog(interp, NSF_LOG_NOTICE, "trying to refetch an epoched cmd %p as %s -- cmdName %s\n", - tcd->aliasedCmd, methodName, ObjStr(targetObj)); + (void *)tcd->aliasedCmd, methodName, ObjStr(targetObj)); /* * Replace cmd and its objProc and clientData with a newly fetched @@ -23733,7 +23735,7 @@ assert(objPtr != NULL); fprintf(stderr, "*** obj %p refCount %d type <%s>\n", - objPtr, objPtr->refCount, (objPtr->typePtr != NULL) ? objPtr->typePtr->name : ""); + (void *)objPtr, objPtr->refCount, (objPtr->typePtr != NULL) ? objPtr->typePtr->name : ""); if (objPtr->typePtr == &NsfObjectMethodObjType || objPtr->typePtr == &NsfInstanceMethodObjType @@ -23746,11 +23748,12 @@ fprintf(stderr, " method epoch %d max %d cmd %p objProc %p flags %.6x\n", mcPtr->methodEpoch, currentMethodEpoch, - cmd, (cmd != NULL) ? ((Command *)cmd)->objProc : 0, + (void *)cmd, + (cmd != NULL) ? ((void *)((Command *)cmd)->objProc) : NULL, mcPtr->flags); if (cmd != NULL) { - fprintf(stderr, "... cmd %p flags %.6x\n", cmd, Tcl_Command_flags(cmd)); - assert(((Command *)cmd)->objProc != NULL); + fprintf(stderr, "... cmd %p flags %.6x\n", (void *)cmd, Tcl_Command_flags(cmd)); + assert(((Command *)cmd)->objProc != NULL); } assert( currentMethodEpoch >= mcPtr->methodEpoch); } @@ -30167,18 +30170,19 @@ if (unlikely(object->refCount != 1)) { if (object->refCount > 1) { NsfLog(interp, NSF_LOG_WARN, "RefCount for obj %p %d (name %s) > 1", - object, object->refCount, ObjectName(object)); + (void *)object, object->refCount, ObjectName(object)); } else { NsfLog(interp, NSF_LOG_WARN, "Refcount for obj %p %d > 1", - object, object->refCount); + (void *)object, object->refCount); } /*object->refCount = 1;*/ } #endif #if !defined(NDEBUG) if (unlikely(object->activationCount != 0)) { - fprintf(stderr, "FinalObjectDeletion obj %p activationcount %d\n", object, object->activationCount); + fprintf(stderr, "FinalObjectDeletion obj %p activationcount %d\n", + (void *)object, object->activationCount); } #endif assert(object->activationCount == 0); Index: generic/nsfDebug.c =================================================================== diff -u -r658c5ca127345b3f4377e551d5e9517c6481b473 -rbf951b5e794b88907333c62b9ebfdaf13c2f26dc --- generic/nsfDebug.c (.../nsfDebug.c) (revision 658c5ca127345b3f4377e551d5e9517c6481b473) +++ generic/nsfDebug.c (.../nsfDebug.c) (revision bf951b5e794b88907333c62b9ebfdaf13c2f26dc) @@ -131,15 +131,15 @@ } while (f) { Tcl_Obj *cmdObj = Tcl_NewObj(); - fprintf(stderr, "\tFrame=%p ", f); + fprintf(stderr, "\tFrame=%p ", (void *)f); if (f && f->isProcCallFrame && f->procPtr && f->procPtr->cmdPtr) { - fprintf(stderr,"caller %p ", Tcl_CallFrame_callerPtr(f)); - fprintf(stderr,"callerV %p ", Tcl_CallFrame_callerVarPtr(f)); + fprintf(stderr,"caller %p ", (void *)Tcl_CallFrame_callerPtr(f)); + fprintf(stderr,"callerV %p ", (void *)Tcl_CallFrame_callerVarPtr(f)); Tcl_GetCommandFullName(interp, (Tcl_Command)f->procPtr->cmdPtr, cmdObj); - fprintf(stderr, "%s (%p) lvl=%d\n", ObjStr(cmdObj), f->procPtr->cmdPtr, f->level); + fprintf(stderr, "%s (%p) lvl=%d\n", ObjStr(cmdObj), (void *)f->procPtr->cmdPtr, f->level); } else { if (f && f->varTablePtr) { - fprintf(stderr, "var_table = %p ", f->varTablePtr); + fprintf(stderr, "var_table = %p ", (void *)f->varTablePtr); } fprintf(stderr, "- \n"); } @@ -148,9 +148,9 @@ } fprintf (stderr, " VARFRAME:\n"); - fprintf(stderr, "\tFrame=%p ", v); + fprintf(stderr, "\tFrame=%p ", (void *)v); if (v != NULL) { - fprintf(stderr, "caller %p var_table %p ", v->callerPtr, v->varTablePtr); + fprintf(stderr, "caller %p var_table %p ", (void *)v->callerPtr, (void *)v->varTablePtr); /* if (v->varTablePtr != NULL) panic(0, "testing");*/ } @@ -191,7 +191,7 @@ fprintf(stderr, "%s", string); for (j = 0; j < objc; j++) { /*fprintf(stderr, " objv[%d]=%s, ", j, objv[j] ? ObjStr(objv[j]) : "NULL");*/ - fprintf(stderr, " objv[%d]=%s %p, ", j, objv[j] ? ObjStr(objv[j]) : "NULL", objv[j]); + fprintf(stderr, " objv[%d]=%s %p, ", j, objv[j] ? ObjStr(objv[j]) : "NULL", (void *)objv[j]); } fprintf(stderr, "\n"); } Index: generic/nsfStack.c =================================================================== diff -u -r24571ae44c492c681d3efd2f2d2f5169ad7d6d57 -rbf951b5e794b88907333c62b9ebfdaf13c2f26dc --- generic/nsfStack.c (.../nsfStack.c) (revision 24571ae44c492c681d3efd2f2d2f5169ad7d6d57) +++ generic/nsfStack.c (.../nsfStack.c) (revision bf951b5e794b88907333c62b9ebfdaf13c2f26dc) @@ -117,7 +117,7 @@ Tcl_CallFrame *framePtr; fprintf(stderr, "NsfShowStack framePtr %p varFramePtr %p\n", - Tcl_Interp_framePtr(interp), Tcl_Interp_varFramePtr(interp)); + (void *)Tcl_Interp_framePtr(interp), (void *)Tcl_Interp_varFramePtr(interp)); /* framePtr = (Tcl_CallFrame *)Tcl_Interp_varFramePtr(interp); for (; framePtr; framePtr = Tcl_CallFrame_callerPtr(framePtr)) { fprintf(stderr, "... frame %p flags %.6x cd %p objv[0] %s\n", @@ -134,21 +134,25 @@ ((NsfCallStackContent *)Tcl_CallFrame_clientData(framePtr)) : NULL; fprintf(stderr, "... %16p %.6x %16p %3d %16p %s ov %s %d", - framePtr, frameFlags, + (void *)framePtr, frameFlags, Tcl_CallFrame_clientData(framePtr), Tcl_CallFrame_level(framePtr), - Tcl_CallFrame_nsPtr(framePtr), Tcl_CallFrame_nsPtr(framePtr)->fullName, + (void *)Tcl_CallFrame_nsPtr(framePtr), Tcl_CallFrame_nsPtr(framePtr)->fullName, Tcl_CallFrame_objc(framePtr) && 0 ? ObjStr(Tcl_CallFrame_objv(framePtr)[0]) : "(null)", Tcl_CallFrame_objc(framePtr) ? Tcl_CallFrame_objc(framePtr) : -1); if (cscPtr != NULL) { fprintf(stderr, " csc %p frameType %.4x flags %.6x (%s.%p %s)\n", - cscPtr, (cscPtr != NULL) ? cscPtr->frameType : -1, (cscPtr != NULL) ? cscPtr->flags : -1, (cscPtr != NULL) ? ObjectName(cscPtr->self) : "", (cscPtr != NULL) ? cscPtr->cmdPtr : NULL, (cscPtr != NULL) ? Tcl_GetCommandName(interp, cscPtr->cmdPtr) : "" + (void *)cscPtr, (cscPtr != NULL) ? cscPtr->frameType : -1, + (cscPtr != NULL) ? cscPtr->flags : -1, + (cscPtr != NULL) ? ObjectName(cscPtr->self) : "", + (cscPtr != NULL) ? (void *)cscPtr->cmdPtr : NULL, + (cscPtr != NULL) ? Tcl_GetCommandName(interp, cscPtr->cmdPtr) : "" ); } else { fprintf(stderr, " no csc"); if (frameFlags & FRAME_IS_NSF_OBJECT) { NsfObject *object = (NsfObject *)Tcl_CallFrame_clientData(framePtr); - fprintf(stderr, " obj %p %s", object, ObjectName(object)); + fprintf(stderr, " obj %p %s", (void *)object, ObjectName(object)); } fprintf(stderr, "\n"); }