Index: TODO =================================================================== diff -u -rcae9407ff24389d6f950a07279adb31750793e02 -r2161e45d79dd066d33b750bf462f0024331ae02c --- TODO (.../TODO) (revision cae9407ff24389d6f950a07279adb31750793e02) +++ TODO (.../TODO) (revision 2161e45d79dd066d33b750bf462f0024331ae02c) @@ -3352,6 +3352,7 @@ * partly simplified interp.test syntactically * deacivated a few tests in interp.test for the time being (runs commands after finalize) + * re-established assertion checking for deleted cmds in cmd lists TODO: - private: Index: generic/nsf.c =================================================================== diff -u -rcae9407ff24389d6f950a07279adb31750793e02 -r2161e45d79dd066d33b750bf462f0024331ae02c --- generic/nsf.c (.../nsf.c) (revision cae9407ff24389d6f950a07279adb31750793e02) +++ generic/nsf.c (.../nsf.c) (revision 2161e45d79dd066d33b750bf462f0024331ae02c) @@ -5973,17 +5973,11 @@ if (startCl->opt) { NsfCmdList *m; NsfClass *cl; + for (m = startCl->opt->isClassMixinOf; m; m = m->nextPtr) { - /* - * HIDDEN OBJECTS: We may encounter situations in which the assertion - * about an cmdEpoch == 0 is too strict. Hidden and re-exposed commands - * have a cmdEpoch > 0. See Tcl_HideCommand() and - * Tcl_ExposeCommand(). Later uses of the command pointer collected here - * (e.g., dispatches) must verify the epoch or perform a safety check by - * refetching the command token. - */ - assert(m->cmdPtr); /* assert(Tcl_Command_cmdEpoch(m->cmdPtr) == 0); */ + /* we should have no deleted commands in the list */ + assert((Tcl_Command_flags(m->cmdPtr) & CMD_IS_DELETED) == 0); cl = NsfGetClassFromCmdPtr(m->cmdPtr); assert(cl); @@ -6005,16 +5999,10 @@ NsfObject *object; for (m = startCl->opt->isObjectMixinOf; m; m = m->nextPtr) { - /* - * HIDDEN OBJECTS: We may encounter situations in which the assertion - * about an cmdEpoch == 0 is too strict. Hidden and re-exposed commands - * have a cmdEpoch > 0. See Tcl_HideCommand() and - * Tcl_ExposeCommand(). Later uses of the command pointer collected here - * (e.g., dispatches) must verify the epoch or perform a safety check by - * refetching the command token. - */ - assert(m->cmdPtr); /* assert(Tcl_Command_cmdEpoch(m->cmdPtr) == 0); */ + /* we should have no deleted commands in the list */ + assert((Tcl_Command_flags(m->cmdPtr) & CMD_IS_DELETED) == 0); + object = NsfGetObjectFromCmdPtr(m->cmdPtr); assert(object); @@ -6100,17 +6088,10 @@ NsfCmdList *m; for (m = startCl->opt->isClassMixinOf; m; m = m->nextPtr) { + + /* we should have no deleted commands in the list */ + assert((Tcl_Command_flags(m->cmdPtr) & CMD_IS_DELETED) == 0); - /* - * HIDDEN OBJECTS: We may encounter situations in which the assertion - * about an cmdEpoch == 0 is too strict. Hidden and re-exposed commands - * have a cmdEpoch > 0. See Tcl_HideCommand() and - * Tcl_ExposeCommand(). Later uses of the command pointer collected here - * (e.g., dispatches) must verify the epoch or perform a safety check by - * refetching the command token. - */ - assert(m->cmdPtr); /* assert(Tcl_Command_cmdEpoch(m->cmdPtr) == 0); */ - cl = NsfGetClassFromCmdPtr(m->cmdPtr); assert(cl); @@ -6164,15 +6145,8 @@ for (m = startCl->opt->classmixins; m; m = m->nextPtr) { - /* - * HIDDEN OBJECTS: We may encounter situations in which the assertion - * about an cmdEpoch == 0 is too strict. Hidden and re-exposed commands - * have a cmdEpoch > 0. See Tcl_HideCommand() and - * Tcl_ExposeCommand(). Later uses of the command pointer collected here - * (e.g., dispatches) must verify the epoch or perform a safety check by - * refetching the command token. - */ - assert(m->cmdPtr); /* assert(Tcl_Command_cmdEpoch(m->cmdPtr) == 0); */ + /* we should have no deleted commands in the list */ + assert((Tcl_Command_flags(m->cmdPtr) & CMD_IS_DELETED) == 0); cl = NsfGetClassFromCmdPtr(m->cmdPtr); assert(cl);