rust/src/librustc/middle
Michael Woerister 40e0541309 debuginfo: Make names of types in debuginfo reliable and omit source locations from debug info type descriptions.
So far, type names generated for debuginfo where a bit sketchy. It was not clearly defined when a name should be fully qualified and when not, if region parameters should be shown or not, and other things like that.
This commit makes the debuginfo module responsible for creating type names instead of using ppaux::ty_to_str() and brings type names, as they show up in the DWARF information, in line with GCC and Clang:

* The name of the type being described is unqualified. It's path is defined by its position in the namespace hierarchy.
* Type arguments are always fully qualified, no matter if they would actually be in scope at the type definition location.

Care is also taken to reliably make type names consistent across crate boundaries. That is, the code now tries make the type name the same, regardless if the type is in the local crate or reconstructed from metadata. Otherwise LLVM will complain about violating the one-definition-rule when using link-time-optimization.

This commit also removes all source location information from type descriptions because these cannot be reconstructed for types instantiated from metadata. Again, with LTO enabled, this can lead to two versions of the debuginfo type description, one with and one without source location information, which then triggers the LLVM ODR assertion.
Fortunately, source location information about types is rarely used, so this has little impact. Once source location information is preserved in metadata (#1972) it can also be reenabled for type descriptions.
2014-07-02 13:32:57 +02:00
..
borrowck Remove unnecessary to_string calls 2014-06-26 08:56:49 +02:00
cfg
save librustc: Remove the fallback to int for integers and f64 for 2014-06-29 11:47:58 -07:00
trans debuginfo: Make names of types in debuginfo reliable and omit source locations from debug info type descriptions. 2014-07-02 13:32:57 +02:00
typeck auto merge of #15069 : luqmana/rust/cia, r=pcwalton 2014-07-02 03:56:29 +00:00
astencode.rs Rename all raw pointers as necessary 2014-06-28 11:53:58 -07:00
check_const.rs
check_loop.rs
check_match.rs librustc: Check function argument patterns for legality of by-move 2014-06-24 17:23:41 -07:00
check_static.rs
const_eval.rs Fix #15129 2014-06-24 17:22:48 -07:00
dataflow.rs librustc: Remove the fallback to int from typechecking. 2014-06-24 17:18:48 -07:00
dead.rs rustc: Remove &str indexing from the language. 2014-07-01 19:12:29 -07:00
def.rs
dependency_format.rs
effect.rs
entry.rs
expr_use_visitor.rs
freevars.rs
graph.rs
intrinsicck.rs
kind.rs librustc: Ensure that proc upvars have static lifetime. 2014-06-26 15:16:03 -07:00
lang_items.rs
liveness.rs rustc: Remove &str indexing from the language. 2014-07-01 19:12:29 -07:00
mem_categorization.rs rustc: Remove &str indexing from the language. 2014-07-01 19:12:29 -07:00
pat_util.rs
privacy.rs Convert builtin lints to uppercase names for style consistency 2014-06-24 11:36:27 -07:00
reachable.rs
region.rs
resolve_lifetime.rs
resolve.rs auto merge of #15160 : alexcrichton/rust/remove-f128, r=brson 2014-06-25 04:31:19 +00:00
stability.rs rustdoc: incorporate stability index throughout 2014-06-30 22:36:24 -07:00
subst.rs Rename all raw pointers as necessary 2014-06-28 11:53:58 -07:00
ty_fold.rs RegionFolder should only invoke callback on free regions. 2014-06-22 06:19:56 +02:00
ty.rs auto merge of #15085 : brson/rust/stridx, r=alexcrichton 2014-07-02 05:41:30 +00:00
weak_lang_items.rs