rust/src/librustc/middle
bors f7a2371c17 auto merge of #5614 : graydon/rust/static-linkage-bug, r=catamorphism
re bug that @nikomatsakis was hitting: when you define a `static` (old: `const`) containing a `&` or `&[]` expression, it will create temporaries (the underlying pointee) by creating a throwaway symbol for each temporary, each with _global_ linkage, and each named `"const"`. LLVM will helpfully rename multiple copies of this throwaway symbol to `"const1"` and `"const2"` and so forth in the _same_ library. But if you have _2 libraries_ -- say, libcore and librustc -- that both do this, the dynamic linker (at least on linux) will happily do horrible things like make the slice in one library point to the bytes of the vector from the other library. This is obviously a recipe for much hilarity and head-scratching.

The solution is to change the linkage to something else, internal or (in the case of this patch) _private_.

It will require a snapshot to integrate this into stage0 and thereby fix the problem / unblock patches that were hitting this in stage1.
2013-03-28 21:48:49 -07:00
..
borrowck remove sty_by_ref, though traces still remain due to dtors 2013-03-27 07:09:16 -04:00
trans auto merge of #5614 : graydon/rust/static-linkage-bug, r=catamorphism 2013-03-28 21:48:49 -07:00
typeck auto merge of #5593 : luqmana/rust/inline-asm, r=catamorphism 2013-03-28 18:18:46 -07:00
astencode.rs auto merge of #5578 : erickt/rust/incoming, r=jbclements,erickt 2013-03-27 21:51:53 -07:00
check_const.rs syntax: Remove deprecated expr_vstore_fixed 2013-03-27 07:04:16 -07:00
check_loop.rs
check_match.rs rustc: Remove uses of oldmap::HashMap 2013-03-26 19:21:04 -04:00
const_eval.rs syntax: Remove deprecated expr_vstore_fixed 2013-03-27 07:04:16 -07:00
freevars.rs rustc: Remove uses of oldmap::HashMap 2013-03-26 19:21:04 -04:00
kind.rs rustc: Purge of HashMap, fixing segfaulting cases 2013-03-26 19:21:04 -04:00
lang_items.rs librustc: Modify all code to use new lifetime binder syntax 2013-03-26 21:30:17 -07:00
lint.rs librustc: Modify all code to use new lifetime binder syntax 2013-03-26 21:30:17 -07:00
liveness.rs auto merge of #5593 : luqmana/rust/inline-asm, r=catamorphism 2013-03-28 18:18:46 -07:00
mem_categorization.rs rustc: Remove uses of oldmap::HashMap 2013-03-26 19:21:04 -04:00
moves.rs auto merge of #5578 : erickt/rust/incoming, r=jbclements,erickt 2013-03-27 21:51:53 -07:00
pat_util.rs rustc: Remove uses of oldmap::HashMap 2013-03-26 19:21:04 -04:00
privacy.rs Move ast_map::map to LinearMap 2013-03-26 19:21:05 -04:00
region.rs rustc: Remove uses of oldmap::HashMap 2013-03-26 19:21:04 -04:00
resolve.rs librustc: Remove common fields and nested enums from the language 2013-03-28 11:30:01 -07:00
ty.rs librustc: Remove common fields and nested enums from the language 2013-03-28 11:30:01 -07:00