Smart completion of inheritors: correct filtering of duplicates