Skip to content

Creating a tuple of a parameterized string leaks memory #153

Closed
@pcwalton

Description

@pcwalton

Test case:

fn f[T](T x) -> tup(T) {
  ret tup(x);
}

fn main() -> () {
  f("foo");
}

Result:

[pwalton@host-4-84 ~/Source/rust/src] ./bug 
allocation 0x600000 was not freed
rt: fatal, 'leaked memory in rust main loop (1 objects)' failed, rt/memory_region.cpp:99 1 objects

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-runtimeArea: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflows

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions