Determining inheritance from ancestors, not just superclass