[vtk-developers] Exceptions in Tcl wrapping

Prabhu Ramachandran prabhu_r at users.sf.net
Thu Jan 6 12:40:37 EST 2005


>>>>> "AC" == Andy Cedilnik <andy.cedilnik at kitware.com> writes:

    AC> Hi All, I am considering adding exceptions to Tcl wrappings
    AC> and maybe to other ones. The way they would work is that if
    AC> you invoke VTK method that throws exception, the tcl wrapping
    AC> would catch the exception and report it as a Tcl error. This
    AC> way you can gracefully exit application in case of running out
    AC> of memory or something similar.

Didn't Charl post a patch for this (for Python wrappers) a long while
ago?  Here is the thread:

http://public.kitware.com/pipermail/vtk-developers/2004-March/002806.html

Reading that I see that the patch changed quite a bit before anything
was checked in.  

Does VTK generate exceptions now?  I've fallen a lot behind on VTK
from CVS and been mainly using VTK-4.4.  I don't recall discussions
about VTK generating exceptions?

[...]

    AC> Also, I am considering adding the same code to Python wrapping
    AC> if there is any interest.

If VTK objects will generate exceptions then we should really fix the
Python wrappers as well.

I've also been thinking about adding support for weakly referencing
VTK-Python objects.  Does anyone have objections to this?

cheers,
prabhu



More information about the vtk-developers mailing list