Skip to content

stack overflow: recursive struct #23335

Description

@matthiaskrgr
struct A {
    m: A,
}
struct B(Box<A>);

fn main() {}

ra @ f312032

/rust-analyzer analysis-stats .

Database loaded:     664.49ms, 220minstr, 48mb (metadata 314.62ms, 965kinstr, 155kb; build 60.49ms, 172kinstr, 1296b)
  item trees: 1
  dependency lines of code: 1_477_159, item trees: 2_968
  dependency item stats: traits: 858, impl: 9_720, mods: 2_998, macro calls: 5_608, macro rules: 1_062
Item Tree Collection: 4.40s, 23ginstr, 431mb
  Total Statistics:
    crates: 1, mods: 1, decls: 3, bodies: 1, adts: 2, consts: 0, signatures: 3, variants: 2
  Workspace:
    traits: 0, macro_rules macros: 0, proc_macros: 0
    lines of code: 6, item trees: 1
    usages: traits: 0, impl: 0, mods: 0, macro calls: 0, macro rules: 0
  Dependencies:
    lines of code: 1_477_159, item trees: 2_968
    declarations: traits: 858, impl: 9_720, mods: 2_998, macro calls: 5_608, macro rules: 1_062
Item Collection:     2.09s, 11ginstr, 176mb
Crate lang items:    260.52ms, 2522minstr, 31mb
Expression Store Lowering: 149.08µs, 276kinstr, -26kb
  exprs: 1, ??ty: 0 (0%), ?ty: 0 (0%), !ty: 0
  pats: 0, ??ty: 0 (100%), ?ty: 0 (100%), !ty: 0
  panics: 0
Inference:           998.31µs, 705kinstr, 2492kb
MIR lowering:        36.32µs, 45kinstr, 0b
Mir failed bodies: 0 (0%)

thread 'main' (2149086) has overflowed its stack
fatal runtime error: stack overflow, aborting
[1]    2149086 abort      ~/vcs/github/rust-analyzer/target/release/rust-analyzer analysis-stats .

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions