Debugging information for templates works for some object code formats, but not others. It works for stabs(Except that insufficient debugging information for methods of template classes is generated in stabs.) (used primarily in a.out object code, but also in the Solaris 2 version of elf), and the mips version of coff debugging format.
dwarf support is currently minimal, and requires further development.