Skip to content

rp.is_none ICE: struct mistyped as trait instantiated with &'self int #9078

Closed
@pnkfelix

Description

@pnkfelix

This is an ICE on some obviously bogus input code.

struct A<X>;

fn foo<I:A<&'self int>>() { }

fn main() { }

Transcript:

% RUST_LOG=rustc=1 rustc --version /tmp/baz2.rs
/Users/pnkfelix/opt/rust-dbg/bin/rustc 0.8-pre (dd5c737 2013-09-08 12:05:55 -0700)
host: x86_64-apple-darwin
% RUST_LOG=rustc=1 rustc /tmp/baz2.rs
task <unnamed> failed at 'assertion failed: rp.is_none()', /Users/pnkfelix/Dev/Mozilla/rust.git/src/librustc/middle/typeck/collect.rs:1108
error: internal compiler error: unexpected failure
note: the compiler hit an unexpected failure path. this is a bug
note: try running with RUST_LOG=rustc=1 to get further details and report the results to github.com/mozilla/rust/issues
task <unnamed> failed at 'explicit failure', /Users/pnkfelix/Dev/Mozilla/rust.git/src/librustc/rustc.rs:376
% 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions