Skip to content

Closures cause ICE with -Z debug-info #8513

New issue

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

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

Already on GitHub? # to your account

Closed
chris-morgan opened this issue Aug 14, 2013 · 2 comments
Closed

Closures cause ICE with -Z debug-info #8513

chris-morgan opened this issue Aug 14, 2013 · 2 comments
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@chris-morgan
Copy link
Member

Yep, it seems that any use of closures (assuming they don't get optimised out of existence) is broken.

rust 0.8-pre (0efbb25 2013-08-13 23:59:18 -0700)
host: x86_64-unknown-linux-gnu

For example:

$ echo 'fn main() { let _a = ||(); }' | rustc - -Z debug-info
<anon>:1:23: 1:25 error: internal compiler error: debuginfo: FunctionDebugContext should be initialized but is not!
<anon>:1 fn main() { let _a = ||(); }
                                ^~

CC @michaelwoerister

chris-morgan added a commit to chris-morgan/rust-http that referenced this issue Aug 14, 2013
@michaelwoerister
Copy link
Member

I'll look into it. Quite a bit of closure code already works fine (e.g. https://github.com/mozilla/rust/blob/master/src/test/debug-info/lexical-scope-in-stack-closure.rs). This may also be caused by only compiling with -Z debug-info instead of -Z extra-debug-info.

In any case, I'll try to solve this asap :)

@michaelwoerister
Copy link
Member

This will be fixed with my next PR. It's a corner case where no other code (like parameter description) initialized the FunctionDebugContext before its scope map was queried.

michaelwoerister added a commit to michaelwoerister/rust that referenced this issue Aug 16, 2013
@bors bors closed this as completed in 6791021 Aug 18, 2013
flip1995 pushed a commit to flip1995/rust that referenced this issue May 5, 2022
…r=xFrednet

wrong_self_convention allows `is_*` to take `&mut self`

fix rust-lang#8480 and rust-lang#8513
Allowing `is_*` to take `&self` or none is too restrictive.

changelog: FPs: [`wrong_self_convention`] now allows `&mut self` and no self as arguments for `is_*` methods
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants