diff options
| author | Michael Woerister <michaelwoerister@posteo> | 2014-05-30 17:09:16 +0200 |
|---|---|---|
| committer | Michael Woerister <michaelwoerister@posteo> | 2014-06-12 18:39:01 +0200 |
| commit | 0a98a4e422bd2d80ee7910b00c0286f1eefde9c5 (patch) | |
| tree | edffef9227740c6dd55390d39315acb2c6e18d23 /src/test/debuginfo | |
| parent | c0a6f72e8bfea2647da7f63f9f09b2cfeaa161c9 (diff) | |
| download | rust-0a98a4e422bd2d80ee7910b00c0286f1eefde9c5.tar.gz rust-0a98a4e422bd2d80ee7910b00c0286f1eefde9c5.zip | |
debuginfo: Generate cross-crate unique type identifiers for debuginfo types.
With this change, rustc creates a unique type identifier for types in debuginfo. These type identifiers are used by LLVM to correctly handle link-time-optimization scenarios but also help rustc with dealing with inlining from other crates. For more information, see the documentation block at the top of librustc/middle/trans/debuginfo.rs. Fixes #13681.
Diffstat (limited to 'src/test/debuginfo')
| -rw-r--r-- | src/test/debuginfo/cross-crate-type-uniquing.rs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/test/debuginfo/cross-crate-type-uniquing.rs b/src/test/debuginfo/cross-crate-type-uniquing.rs new file mode 100644 index 00000000000..47de06c4856 --- /dev/null +++ b/src/test/debuginfo/cross-crate-type-uniquing.rs @@ -0,0 +1,24 @@ +// Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT +// file at the top-level directory of this distribution and at +// http://rust-lang.org/COPYRIGHT. +// +// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or +// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license +// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your +// option. This file may not be copied, modified, or distributed +// except according to those terms. + +// ignore-android: FIXME(#10381) + +// aux-build:cross_crate_debuginfo_type_uniquing.rs +extern crate cross_crate_debuginfo_type_uniquing; + +// no-prefer-dynamic +// compile-flags:-g -Zlto + +pub struct C; +pub fn p() -> C { + C +} + +fn main() { } \ No newline at end of file |
