about summary refs log tree commit diff
path: root/src/test/debuginfo/generic-struct.rs
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-85/+0
2021-07-19[debuginfo] Adapt CDB tests after changes to whitespace usage in debuginfo ↵Michael Woerister-5/+5
type names.
2021-06-30Improve debug symbol names to avoid ambiguity and work better with MSVC's ↵Daniel Paoliello-0/+21
debugger There are several cases where names of types and functions in the debug info are either ambiguous, or not helpful, such as including ambiguous placeholders (e.g., `{{impl}}`, `{{closure}}` or `dyn _'`) or dropping qualifications (e.g., for dynamic types). Instead, each debug symbol name should be unique and useful: * Include disambiguators for anonymous `DefPathDataName` (closures and generators), and unify their formatting when used as a path-qualifier vs item being qualified. * Qualify the principal trait for dynamic types. * If there is no principal trait for a dynamic type, emit all other traits instead. * Respect the `qualified` argument when emitting ref and pointer types. * For implementations, emit the disambiguator. * Print const generics when emitting generic parameters or arguments. Additionally, when targeting MSVC, its debugger treats many command arguments as C++ expressions, even when the argument is defined to be a symbol name. As such names in the debug info need to be more C++-like to be parsed correctly: * Avoid characters with special meaning (`#`, `[`, `"`, `+`). * Never start a name with `<` or `{` as this is treated as an operator. * `>>` is always treated as a right-shift, even when parsing generic arguments (so add a space to avoid this). * Emit function declarations using C/C++ style syntax (e.g., leading return type). * Emit arrays as a synthetic `array$<type, size>` type. * Include a `$` in all synthetic types as this is a legal character for C++, but not Rust (thus we avoid collisions with user types).
2021-04-03Remove redundant `ignore-tidy-linelength` annotationsSimon Jakobi-2/+0
This is step 2 towards fixing #77548. In the codegen and codegen-units test suites, the `//` comment markers were kept in order not to affect any source locations. This is because these tests cannot be automatically `--bless`ed.
2018-12-25Remove licensesMark Rousskov-10/+0
2018-11-29Add template parameter debuginfo to generic typesTom Tromey-1/+4
This changes debuginfo generation to add template parameters to generic types. With this change the DWARF now has DW_TAG_template_type_param for types, not just for functions, like: <2><40d>: Abbrev Number: 6 (DW_TAG_structure_type) <40e> DW_AT_name : (indirect string, offset: 0x375): Generic<i32> <412> DW_AT_byte_size : 4 <413> DW_AT_alignment : 4 ... <3><41f>: Abbrev Number: 8 (DW_TAG_template_type_param) <420> DW_AT_type : <0x42a> <424> DW_AT_name : (indirect string, offset: 0xa65e): T Closes #9224
2018-10-08Run debuginfo tests against rust-enabled lldb, when possibleTom Tromey-4/+8
If the rust-enabled lldb was built, then use it when running the debuginfo tests. Updating the lldb submodule was necessary as this needed a way to differentiate the rust-enabled lldb, so I added a line to the --version output. This adds compiletest commands to differentiate between the rust-enabled and non-rust-enabled lldb, as is already done for gdb. A new "rust-lldb" header directive is also added, but not used in this patch; I plan to use it in #54004. This updates all the tests.
2016-10-31adapt debuginfo tests for gdb with native rust supportTim Neumann-4/+8
2015-09-19Feature-gate `#[no_debug]` and `#[omit_gdb_pretty_printer_section]`Andrew Paseltiner-0/+1
Closes #28091.
2015-03-27Fix fallout of removing quotes in crate namesAlex Crichton-1/+1
2015-02-10Enable test/debuginfo on androidEunji Jeong-1/+0
2015-01-30Merge remote-tracking branch 'origin/master' into rollupAlex Crichton-4/+4
2015-01-30Remove all `i` suffixesTobias Bucher-4/+4
2015-01-06More test fixesAlex Crichton-4/+4
2014-12-30debuginfo: Add a rust-gdb shell script that will start GDB with Rust pretty ↵Michael Woerister-0/+3
printers enabled.
2014-10-31debuginfo: Make GDB tests use line breakpoints like done in LLDB tests.Michael Woerister-2/+0
On some Windows versions of GDB this is more stable than setting breakpoints via function names.
2014-10-22debuginfo: Gate all LLDB debuginfo tests on a minimum LLDB version being ↵Michael Woerister-0/+1
available
2014-07-16debuginfo: Add LLDB autotests to debuginfo test suite.Michael Woerister-2/+20
This commit adds LLDB autotests to the test suite but does not activate them by default yet.
2014-06-29librustc: Remove the fallback to `int` for integers and `f64` forPatrick Walton-4/+7
floating point numbers for real. This will break code that looks like: let mut x = 0; while ... { x += 1; } println!("{}", x); Change that code to: let mut x = 0i; while ... { x += 1; } println!("{}", x); Closes #15201. [breaking-change]
2014-05-07debuginfo: Split debuginfo autotests into debuginfo-gdb and debuginfo-lldbMichael Woerister-0/+42