#3146 use Tcl_SaveInterpState

obsolete: 8.5a3
closed-accepted
5
2005-07-06
2005-05-24
Don Porter
No

When LinkTraceProc handles
write traces, it calls on
various Tcl_GetFooFromObj()
routines to check the "type"
of the written value, against
the link type. The "interp" is
passed to these calls to capture
error messages.

When there's no error, the impact
on the interp isn't supposed to
be perceived, and LinkTraceProc
saves and restores the interp result
to achieve this.

The interp result is only a part
of the interpreter state. The
new routines
Tcl_(Save|Restore)InterpState
would be better tools to completely
achieve this task.

Discussion

  • Donal K. Fellows

    Logged In: YES
    user_id=79902

    Sounds fair to me

     
  • Don Porter

    Don Porter - 2005-07-06

    Logged In: YES
    user_id=80530

    I think I misread this one.

    LinkTraceProc() is a
    Tcl_VarTraceProc. It gets
    called only by TclCallVarTraces,
    which does its own save/restore
    of the interp state, precisely so
    each trace routine doesn't have to.

     
  • Don Porter

    Don Porter - 2005-07-06

    Logged In: YES
    user_id=80530

    With that in mind, the attached patch
    simplifies LinkTraceProc a good deal.

     
  • Don Porter

    Don Porter - 2005-07-06
     
  • Don Porter

    Don Porter - 2005-07-06
    • status: open --> closed
     
  • Don Porter

    Don Porter - 2005-07-06

    Logged In: YES
    user_id=80530

    Patch applied to HEAD.

    *not* safe for 8.4.

     
  • Don Porter

    Don Porter - 2005-07-06
    • assigned_to: hobbs --> dgp
    • status: closed --> closed-accepted
     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks