Skip to content

Segfault with generic functions #1443

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
marijnh opened this issue Jan 5, 2012 · 0 comments
Closed

Segfault with generic functions #1443

marijnh opened this issue Jan 5, 2012 · 0 comments
Labels
I-crash Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.

Comments

@marijnh
Copy link
Contributor

marijnh commented Jan 5, 2012

The below code segfaults for me. Any further reduction seems to remove the problem.

fn baz<T, U>(s: T, f: block(T) -> U) { f(s); }
fn foo<T>(x: T) { baz(x, {|_e| 0 }); }
fn main() { foo(0); }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
I-crash Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.
Projects
None yet
Development

No branches or pull requests

1 participant