smartptr inheritance fix when using templates and typedefs

Fixes SF bug 3333549 - %shared_ptr fixes when the type is a template using
template parameters that are typedef'd to another type.

Also fixes python -O optimization where the smart pointer conversion to the
base class needs to work because of the virtual methods that have been
optimized away.
This commit is contained in:
William S Fulton 2016-06-20 22:23:34 +01:00
commit 38cda92938
2 changed files with 9 additions and 4 deletions

View file

@ -8,9 +8,8 @@ if d.bar() != 2:
raise RuntimeError
if bar_getter(b) != 1:
raise RuntimeError
# Fix reverted in rev 12953
# if bar_getter(d) != 2:
# raise RuntimeError
if bar_getter(d) != 2:
raise RuntimeError
b = BaseDefaultInt()
d = DerivedDefaultInt()