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

ICE when renaming self to alredy imported module on beta and nighly #56187

Closed
Arvamer opened this issue Nov 23, 2018 · 4 comments
Closed

ICE when renaming self to alredy imported module on beta and nighly #56187

Arvamer opened this issue Nov 23, 2018 · 4 comments
Assignees
Labels
A-resolve Area: Name resolution regression-from-stable-to-beta Performance or correctness regression from stable to beta.

Comments

@Arvamer
Copy link

Arvamer commented Nov 23, 2018

Trying to compile:

use std::io::{self, prelude::{self as io}};

results in:

thread 'main' panicked at 'byte index 4294967293 is out of bounds of `self as io`', src/libcore/str/mod.rs:2094:9
stack backtrace:
   0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
             at src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::_print
             at src/libstd/sys_common/backtrace.rs:71
   2: std::panicking::default_hook::{{closure}}
             at src/libstd/sys_common/backtrace.rs:59
             at src/libstd/panicking.rs:211
   3: std::panicking::default_hook
             at src/libstd/panicking.rs:227
   4: rustc::util::common::panic_hook
   5: std::panicking::rust_panic_with_hook
             at src/libstd/panicking.rs:480
   6: std::panicking::continue_panic_fmt
             at src/libstd/panicking.rs:390
   7: rust_begin_unwind
             at src/libstd/panicking.rs:325
   8: core::panicking::panic_fmt
             at src/libcore/panicking.rs:77
   9: core::str::slice_error_fail
             at src/libcore/str/mod.rs:0
  10: core::str::traits::<impl core::slice::SliceIndex<str> for core::ops::range::RangeTo<usize>>::index::{{closure}}
  11: rustc_resolve::Resolver::report_conflict
  12: rustc_resolve::resolve_imports::ImportResolver::resolve_imports
  13: rustc_resolve::macros::<impl syntax::ext::base::Resolver for rustc_resolve::Resolver<'a, 'crateloader>>::resolve_imports
  14: syntax::ext::expand::MacroExpander::expand_fragment
  15: syntax::ext::expand::MacroExpander::expand_crate
  16: rustc_driver::driver::phase_2_configure_and_expand_inner::{{closure}}
  17: rustc::util::common::time
  18: rustc_driver::driver::phase_2_configure_and_expand
  19: rustc_driver::driver::compile_input
  20: rustc_driver::run_compiler_with_pool
  21: <scoped_tls::ScopedKey<T>>::set
  22: rustc_driver::run_compiler
  23: syntax::with_globals
  24: __rust_maybe_catch_panic
             at src/libpanic_unwind/lib.rs:102
  25: rustc_driver::run
  26: rustc_driver::main
  27: std::rt::lang_start::{{closure}}
  28: std::panicking::try::do_call
             at src/libstd/rt.rs:59
             at src/libstd/panicking.rs:310
  29: __rust_maybe_catch_panic
             at src/libpanic_unwind/lib.rs:102
  30: std::rt::lang_start_internal
             at src/libstd/panicking.rs:289
             at src/libstd/panic.rs:398
             at src/libstd/rt.rs:58
  31: main
  32: __libc_start_main
  33: <unknown>
query stack during panic:
end of query stack

error: internal compiler error: unexpected panic

note: the compiler unexpectedly panicked. this is a bug.

note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.32.0-nightly (00e03ee57 2018-11-22) running on x86_64-unknown-linux-gnu

same with

use std::io;
use std::collections::{self as io};
@petrochenkov petrochenkov self-assigned this Nov 23, 2018
@petrochenkov petrochenkov added A-resolve Area: Name resolution regression-from-stable-to-beta Performance or correctness regression from stable to beta. labels Nov 23, 2018
@petrochenkov
Copy link
Contributor

Bad span arithmetics, looks like a regression from #55113.

I'll try to fix it now, but ping @estebank @mockersf just in case.

@estebank
Copy link
Contributor

@petrochenkov
Copy link
Contributor

Fixed in #56206

bors added a commit that referenced this issue Nov 25, 2018
[beta] resolve: Fix some stable-to-beta regressions

Fixes #56182 (stable-to-beta regression)
Fixes #56187 (stable-to-beta regression)
@alexcrichton
Copy link
Member

Fixed in #56206

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-resolve Area: Name resolution regression-from-stable-to-beta Performance or correctness regression from stable to beta.
Projects
None yet
Development

No branches or pull requests

4 participants