Skip to content
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

'unexpected sort of node' when generating debug info #2765

Closed
jesse99 opened this issue Jun 30, 2012 · 5 comments
Closed

'unexpected sort of node' when generating debug info #2765

jesse99 opened this issue Jun 30, 2012 · 5 comments
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) I-crash Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.

Comments

@jesse99
Copy link
Contributor

jesse99 commented Jun 30, 2012

Trying to build a fork of rust-socket with rust from June 30, 2012 I get the following:

rustc socket.rc -g
error: internal compiler error: create_function: unexpected sort of node
rust: task failed at 'explicit failure', /Users/jessejones/Source/Third_Party/rust/src/libsyntax/diagnostic.rs:78
rust: task failed at 'explicit failure', /Users/jessejones/Source/Third_Party/rust/src/rustc/driver/rustc.rs:258
rust: domain main @0x7f91c1000010 root task failed
rust: task failed at 'killed', /Users/jessejones/Source/Third_Party/rust/src/libcore/task.rs:461
make: *** [all] Error 101

To repro this do the following from a terminal:

git clone https://github.com/jesse99/rust-socket.git
git checkout c23984460cf948d9b8a8f8153db7883ce45ac4e7
make
@jesse99
Copy link
Contributor Author

jesse99 commented Jun 30, 2012

Narrowed it down to the finalizer in:

class socket_handle {
    let sockfd: libc::c_int;
    new(x: libc::c_int) {self.sockfd = x;}
    drop {c::close(self.sockfd);}
}

@brson
Copy link
Contributor

brson commented Jun 30, 2012

I can successfully build the above test case with ba6f71f on 64-bit linux

@jesse99
Copy link
Contributor Author

jesse99 commented Jun 30, 2012

Here is a simple repro:

class socket_handle {
    let sockfd: int;
    new(x: int) {self.sockfd = x;}
    drop {io::println("hmm");}
}

Finally figured out that it works when -g is not used.

@brson
Copy link
Contributor

brson commented Jul 3, 2012

Updated the title to reflect the debuginfo problem.

@catamorphism
Copy link
Contributor

Dup of #2194

oli-obk pushed a commit to oli-obk/rust that referenced this issue Jan 30, 2023
add scfix test

I'm not sure if we currently *guarantee* to pass this test, but at least I was unable to get it to fail.

Cc `@cbeuw`
RalfJung pushed a commit to RalfJung/rust that referenced this issue Feb 26, 2023
add scfix test

I'm not sure if we currently *guarantee* to pass this test, but at least I was unable to get it to fail.

Cc `@cbeuw`
celinval added a commit to celinval/rust-dev that referenced this issue Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) 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

3 participants