Would it be possible to make the error instead: > required type for s: type Float32Sort (defined at file1.nim:17:3) > but > expression 'Float32Sort_3735007' is of type: type Float32Sort (defined at > file2.nim:917:1)
Or something like that? That would make it less confusing. Perhaps having it always is information overload and it should only be provided if the string representing the type name is the same? That's not a complete solution, because I except that this problem would happen mostly with template/macro instantiations from the same template/macro (and thus the exact same point of definition...). A complete solution, perhaps, would need a stack of the source locations of all template/macro expansions that lead to the type definition, and then eliminating the common prefixes and suffixes between the mismatched types to point to where the problem exactly is. (Have no idea if the compiler even keeps all this info, and if it does - whether the implementation complexity is worth it for this)