On Fri, Jul 15, 2011 at 1:45 PM, Prabhu Ramachandran <span dir="ltr"><<a href="mailto:prabhu@aero.iitb.ac.in">prabhu@aero.iitb.ac.in</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div class="im"><br></div>
So it seems like the only way around this is to actually mangle the names to make them legitimate as you say below.<div class="im">
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I could change the python names of the template instantiations to a<br>
mangled form to make them python-legit,<br>
<br>
vtkVector3<float> -> 'T10vtkVector3IfE'<br>
vtkVector<float,3> -> 'T9vtkVectorIfLi3EE'<br>
</blockquote>
<br></div>
Why not, vtkVector3_float or vtkVector3_float_3?  Underscores are not used in any other VTK class names.<br></blockquote><div><br></div><div>I already have code in VTK to do gcc-style mangling, which is what I showed above -- it's ugly, but it is a documented standard. Also, the names don't necessarily have to be human-readable, since the purpose here is to enable code introspection tools like yours.  Users will still typically instantiate the templates as vtkVector['float32', 3] as I described in README_WRAP.txt.</div>

<div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
I've attached a really simple script.  I have a test suite to catch these so once this is fixed I'll report any additional issues.<br>
<br>
If you'd like, I can also send you the full wrapper generation code off-list.  It only depends on standard Python + VTK-Python.<br></blockquote><div><br></div><div>Sure, it might be useful for me to take a peek.</div>

<div><br></div><div> - David</div><div><br></div></div>