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

Regression in typeck from beta to nightly #38363

Closed
raggy-rs opened this issue Dec 14, 2016 · 2 comments · Fixed by #38375
Closed

Regression in typeck from beta to nightly #38363

raggy-rs opened this issue Dec 14, 2016 · 2 comments · Fixed by #38375
Labels
regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@raggy-rs
Copy link

raggy-rs commented Dec 14, 2016

Works on stable and beta but not on nigthly

I tried this code in the playground:

struct X {
    a: [usize;26],
}
impl X {
    pub fn foo()->Self{
        let a = [usize;5];
        X{a:a}
    }
}

I expected to get:

error[E0425]: unresolved name `usize`

Instead, this happened:

error: internal compiler error: ../src/librustc_typeck/check/mod.rs:4396: unexpected definition: PrimTy(TyUint(usize))

Meta

rustc 1.15.0-nightly (daf8c1dfc 2016-12-05)
Backtrace:
  15:      0x7fec6098187 - rustc_typeck::check::FnCtxt::check_stmt::h155d968e61fdfae6
  16:      0x7fec60984be - rustc_typeck::check::FnCtxt::check_block_no_value::h3ac235dc3eaa76c3
  17:      0x7fec608326e - rustc_typeck::check::FnCtxt::check_struct_path::h1ff2872963f8985c
  18:      0x7fec6082d81 - rustc_typeck::check::FnCtxt::check_struct_path::h1ff2872963f8985c
  19:      0x7fec6062c1d - <rustc_typeck::coherence::orphan::OrphanChecker<'cx, 'tcx> as rustc::hir::itemlikevisit::ItemLikeVisitor<'v>>::visit_im
pl_item::habbc901b4cfa4531
  20:      0x7fec6060f57 - rustc_typeck::check::check_drop_impls::hb6e6926f4342f9e2
  21:      0x7fec6065296 - rustc_typeck::check::check_item_body::h1e039ede2f960fb9
  22:      0x7fec605dbbd - rustc_typeck::check::check_item_bodies::hd22adb7703cc56d7
  23:      0x7fec60ea500 - rustc_typeck::check_crate::h92f6bdfe03b6afba
  24:      0x7fecec9c98e - rustc_driver::driver::count_nodes::h84f03318ea2320a8
  25:      0x7fecebf5bcf - <unknown>
  26:      0x7fecec78932 - rustc_driver::driver::compile_input::h8e119234b60571d5
  27:      0x7fececc9f27 - rustc_driver::run_compiler::h57c4f233cd1a0c04
  28:      0x7fecebada1e - <unknown>
  29:      0x7fec8f85bf1 - _rust_maybe_catch_panic
  30:      0x7fecebd7794 - <unknown>
  31:      0x7fec8f7d86e - std::sys::imp::thread::Thread::new::hd990f5dcc0d4bad9
  32:         0x76f059cc - BaseThreadInitThunk
@petrochenkov
Copy link
Contributor

Duplicate of #38155, fixed in #38154

@steveklabnik steveklabnik added A-compiler regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Dec 14, 2016
@steveklabnik
Copy link
Member

Closing as a duplicate, thanks!

bors added a commit that referenced this issue Dec 15, 2016
Fix regression in resolution of primitive types

Fix often encountered ICE.
Extracted from #38154
Fixes #38155, fixes #38188, fixes #38277, fixes #38280, fixes #38292, fixes #38311, fixes #38344, fixes #38363, fixes #38372 (duplicates)

r? @jseyfried or @eddyb or @nrc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants