-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
[WIP] middle/check_const: CheckItemRecursion should only recurse into NodeItems #14262
Conversation
@alexcrichton, would you happen to have the text from my comment on #13950 describing the state of my debugging sitting in your email inbox? If so, you could paste it here. Somehow Github dropped it and unfortunately this was my only copy. |
Does this do anything to address a case like the following? extern { static X: uint; }
static Y: uint = X; (i.e. trying to refer to the actual value of the extern constant, not the address.) |
Also, it seems like it may close #13325 (depending on the answer to my comment at the end)? |
This is the last message I have in my inbox about the old PR, the one you were looking for? @alexcrichton, thanks! I've been working on this but I've been on the road so there have been few opportunities to post updates. It seems this commit is only a partial fix. While the code that lead me to find this issue now compiles, the test case included in this set still crashes, as the CI run demonstrates. The problem appears to be a lack of handling of mutable statics in middle::trans::const_expr_unadjusted. In the case of the included test case the following happens,
Going to be on and off of flights for the next 12 hours or so but I'll be online intermittently. |
@alexcrichton, indeed that's the one. Thanks! |
Closing due to inactivity, but feel free to reopen with a rebase! |
I just pushed a rebase and will have a stab at finishing this up now. |
Closing due to inactivity, but feel free to reopen with a rebase! |
I seem to be running into this again. I'll try dusting off the patch again. |
Hmm, never mind; I'm actually see #18164 now. |
Note: This used to be #13950. Unfortunately due to poor branch management practices on my part, I had to close it in favor of this issue.
This fixes a bug in
libsyntax
which would crash on ASTs containing references to foreign externs. Previously the included test would fail with,