Indexing code for extended types